Re: [sqlite] Select the top N rows from each group

2007-05-11 Thread Clark Christensen
TED]> To: sqlite-users@sqlite.org Sent: Friday, May 11, 2007 2:44:30 PM Subject: [sqlite] Select the top N rows from each group I need to select top 2 (or N) most expensive fruits of each type from this table: +++---+ | type | variety|

[sqlite] Select the top N rows from each group

2007-05-11 Thread Yuriy Martsynovskyy
I need to select top 2 (or N) most expensive fruits of each type from this table: +++---+ | type | variety| price | +++---+ | apple | gala | 2.79 | | apple | fuji | 0.24 | | apple | limbertwig | 2.87 | | orange | valencia |