title: Duplicate content in LEFT JOIN query + get count on joined table
body: <p>I am trying to join two tables with similar ids, then get a sum of two fields as well. let me explain:</p>
  
  <p><strong>test table:</strong> id | post | desc | Date</p>
  
  <p><strong>likes_dislikes table:</strong> id | song_id | user_ip | like | dislike</p>
  
  <p>on test 'test table', the 'id' matches that of the likes_dislikes 'song_id', so I tried LEFT JOIN since not every post will have an id in the likes_dislikes table, but I got duplicate results .</p>
  
  <pre><code>SELECT *
  FROM
    test
    LEFT JOIN likes_dislikes ON test.song_id = likes_dislikes.page_id
  GROUP BY test.song_id
  ORDER BY test.id DESC LIMIT $start, $limit
  </code></pre>
  
  <p>how can I prevent the duplicate content, and also, get the TOTAL likes/dislikes associated with each post as I run through a while loop?</p>