It works for posts with comments because you're grouping only the posts that have comments.
When you've got an aggregate function in the select (ie: SUM/MAX/AVG/etc) then you group by all other fields in the select.
ie:
code:
GROUP BY kj_posts.ID, kj_posts.post_date, kj_posts.post_title
Also, you shouldn't need that WHERE 1=1 (unless you have a fancy set of PHP if conditions hiding a selection of AND/ORs under it)
EDITED: 22 Oct 2006 14:03 by BOUGHTONP