I have a table "record: id,name,score" and would like to query for the 2 highest scores per each name. I am using group by to get the highest score as :
select name,max(score)as score from record group by name order by score
But I think its not possible to get the 2 highest scores using group by, how do I get them ?