title: postgresql, select empty string
body: <p>To query empty fields I have seen this answer:
  <a href="https://stackoverflow.com/questions/14172978/postgresql-select-empty-fields">Postgresql, select empty fields</a></p>
  <p>(unfortunately I don't have enough reputation points to answer @wildplasser on that post, so here we go)</p>
  <p>Wildplasser's answer:</p>
  <pre><code>SELECT mystr, mystr1 
  FROM mytable 
  WHERE COALESCE(mystr, '') = '' 
     OR COALESCE(mystr1, '') = ''
      ;
  </code></pre>
  <hr />
  <p>I am not sure I get the COALESCE method, but it also works for me this way (specific for my string data type):</p>
  <pre><code>SELECT mystr, mystr1 
  FROM mytable 
  WHERE mystr = '' ;
  </code></pre>
  <hr />
  <p><strong>My questions are:</strong></p>
  <ol>
  <li><p><em>Does COALESCE work for any data type?</em></p>
  </li>
  <li><p><em>Is there any better way to query empty strings? i.e., column_value = ' '</em></p>
  </li>
  </ol>