0
How do I select all records in select below:
$select = "SELECT COUNT(1) AS id_mark, SUM(a.rate) AS rate, b.name_mark, b.id 
           FROM tb_comment a, tb_mark b 
           WHERE a.id_mark=b.id AND b.id_category=:id_c 
           GROUP BY a.id_mark, b.name_mark 
           ORDER BY rate DESC 
           LIMIT $start_pg, $amount_pg";
Why on this SELECT is just selecting the 'items' that has some value in 'rate', there would be no way to select everything and those that do not have value to show '0' as value?
On the table tb_mark has all entries*[topics]* and in the table tb_comment has all the records of comments from topics, and select is only displaying the entries that have some record in the table tb_comment.