title: Count empty text fields in CASE sentence in MySQL
body: <p>My column contains categories A, B, C or "empty" ( which means the record is not categorized). </p>
  
  <p>I want to show the total number of  A's, B's and C's and the total number of records "Not categorized", and have tried the query below. </p>
  
  <p>It does not work, however. It shows the correct number of A, B and C's but not the number of not categorized. </p>
  
  <pre><code>SELECT count(*) AS Quantity,
         CASE
             WHEN cf_ab_contacts.col_621 = '' THEN "Uncategorized"
             ELSE cf_ab_contacts.col_621  
         END AS `Category`
  FROM ...
  WHERE ...
  GROUP BY `cf_ab_contacts`.`col_621`;
  </code></pre>
  
  <p>Thanks for all help. </p>