title: How to union queries from the same table in MySQL
body: <p>I have two sets of results:</p>
  
  <pre><code>SELECT name, count(appearance) as countA from table where results = '1'
  SELECT name, count(appearance) as countB from table where results = '2'
  </code></pre>
  
  <p>And I wanted to combine them side by side, like this:</p>
  
  <pre><code>+---------+---------+---------+
  | col_1   | countA  | countB  |
  +---------+---------+---------+
  | John    |    3    |    1    |
  | Mary    |    1    |    2    |
  | Gary    |    2    |   NULL  |
  | Sean    |    4    |   NULL  |
  | Mike    |  NULL   |    6    |
  +---------+---------+---------+
  </code></pre>
  
  <p>How do I do that?</p>