I've two tables. Posts and Replies. Think about posts like a blog entry while replies would be the comments.

I wish to display X quantity of posts and so the latest three comments for each one of the posts.

My replies includes a foreign key "publish_id" which fits the "id" of each and every publish.

I'm trying to produce a primary page which has something like

Publish --Reply --Reply --Reply

Publish --Reply

the like and thus 4th. I'm able to make this happen using a for loop during my template and getting rid of the needless replies however i hate getting data from the db I will not use. Any ideas?