返回顶部

mysql如何实现分组查询每个班级的最高分?

4

0/300

评论 1

Kola@小象学院

实现代码如下所示: select a.class, a.score from student a inner join (select max(score) as score, class as class from student group by class ) b on a.class=b.class and a.score=b.score;

2021-09-01 16:01:57

- 没有更多了 -