I have 2 tables: comments & posts. I'd like to display a list of 15 posts and maximum 2 most recent comments under each blog post entry using mysql.
the database scheme looks like this
posts_table:
post_id, post_txt, post_timestamp
comments_table:
post_id, comment_txt, comment_timestamp
how should the mysql query look in order to select 15 posts and their related comments (max 2 most recent ones per post)?
thanks