SELECT * FROM cms_newscomments GROUP BY news_id ORDER BY comment_date DESC
That code does not do what I was wanting. I wanted all similar news id's to be grouped together, like below
News ID : 1
Comment ID : 1
Comment Post : good stuff
Comment Date : 20050108223904
Comment Author : jambo182
Edit || Delete
News ID : 2
Comment ID : 5
Comment Post : blah blah blah
Comment Date : 20050211122341
Comment Author : jambo182
Edit || Delete
News ID : 2
Comment ID : 3
Comment Post : blah blah dsgrg
Comment Date : 20050211122341
Comment Author : jambo182
Edit || Delete
News ID : 5
Comment ID : 2
Comment Post : cool article!
Comment Date : 20050210173220
Comment Author : jambo182
Edit || Delete
News ID : 5
Comment ID : 4
Comment Post : cool article!
Comment Date : 20050210173220
Comment Author : jambo182
Edit || Delete
Problem is, it is only showing one news_comment associated with each News_ID
Like below:
News ID : 2
Comment ID : 5
Comment Post : blah blah blah
Comment Date : 20050211122341
Comment Author : jambo182
Edit || Delete
News ID : 5
Comment ID : 2
Comment Post : cool article!
Comment Date : 20050210173220
Comment Author : jambo182
Edit || Delete
News ID : 1
Comment ID : 1
Comment Post : good stuff
Comment Date : 20050108223904
Comment Author : jambo182
Edit || Delete
How would I amend the query to show it in the format I am looking for?
Cheers
klik