course
cr_id cr_name
11 语文
12 数学
13 英语
score
cr_id st_id score
11 1 25
11 2 25
11 3 11
12 1 21
12 2 22
12 3 23
13 1 21
13 2 22
13 3 23
student
st_id st_name
1 张
2 李
3 王
select * from score a where score in (SELECT MAX(score) from score s GROUP BY s.cr_id);
select * from score a where a.score = (SELECT MAX(score) from score s where s.cr_id=a.cr_id);
select b.cr_name,a.score,c.st_name from
(select * from score a where score in (SELECT MAX(score) from score s GROUP BY s.cr_id))a,
course b,
student c
where a.cr_id=b.cr_id and a.st_ID=c.st_id