How to select a limited amount of rows for each foreign key?

Posted by Keyne on Stack Overflow See other posts from Stack Overflow or by Keyne
Published on 2010-04-07T05:11:36Z Indexed on 2010/04/07 5:13 UTC
Read the original article Hit count: 263

Filed under:
|

Hi, I have this table:

id
feed_id
...

Let's say that I have 500 rows and I want to select 3 entries for each feed_id? And 50 as total limit.

How to write this SQL?

© Stack Overflow or respective owner

Related posts about mysql

Related posts about sql