欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

mysql 查詢表中平均分最低的班級

 更新時間:2009年07月09日 14:03:39   作者:  
查詢出dd(user_id,class_no,score)這個表中平均分最低的班級?
復制代碼 代碼如下:

drop table if exists dd;
create table dd (
user_id int ,
class_no int ,
score int
);
insert into dd values (1,1,1), (2,1,1), (3,1,2), (4,2,2);
select class_no ,avg(score)from dd group by class_no order by avg(score);

在MySQL下面測試通過。

相關(guān)文章

最新評論