title: Postgresql insert trigger to set value
body: <p>Assume in Postgresql, I have a table <code>T</code> and one of its column is <code>C1</code>. </p>
  
  <p>I want to trigger a function when a new record is adding to the table <code>T</code>. The function should check the value of column <code>C1</code> in the new record and if it is null/empty then set its value to <code>'X'</code>. </p>
  
  <p>Is this possible? </p>