title: Unexpected results from an sql query which uses RIGHT JOIN
body: <p>I have an sql query which seems to return an unexpected blank row. This query has an right join to another table but when return the rows it returns me a null value..</p>
  
  <pre><code>  SELECT e.error_id, e.user_id, e.error_title, e.error_content, e.error_answers, 
           e.error_votes, e.error_views, e.error_added_date, u.user_name
    FROM errors e
    JOIN users u
      ON u.user_id=e.user_id
    RIGHT JOIN answers a
      ON a.error_id=e.error_id AND a.answer_accepted='1'
    GROUP BY e.error_id
    ORDER BY e.error_added_date DESC
  </code></pre>
  
  <p>This query should return me one single row but It returns me the expected row and one row with blank values.. Why is that?</p>
  
  <p><strong>Entries</strong></p>
  
  <pre><code>+----------------------------------------------------------------------------------------------------+
  answer_id | error_id | user_id | answer_content | answer_accepted | answer_votes | answer_added_date |
  1         | 3        | 1       | text           | 0               | 0            | 2013-01-31 12:49:12
  2         | 3        | 1       | text           | 1               | 1            | 2013-01-31 12:52:29
  3         | 3        | 1       | text           | 0               |-1            | 2013-01-31 12:53:45
  4         | 2        | 1       | text           | 0               |-1            | 2013-01-31 12:53:45
  +----------------------------------------------------------------------------------------------------+
  </code></pre>
  
  <p>Results:</p>
  
  <pre><code>+-------------------------------------------------------------------------------+
  |   1 | 1    | text |  3   | 0    |  2   |  2013-01-29 16:56:20  |  Mihai Matei |
  |NULL | NULL | NULL | NULL | NULL | NULL |       NULL            |  NULL        |
  +-------------------------------------------------------------------------------+
  </code></pre>