题解 | #分组排序练习题#
分组排序练习题
https://www.nowcoder.com/practice/e00bbac732cb4b6bbc62a52b930cb15e
//平均值avg,按学校分组,按平均发帖数升序排列
select university,
avg(question_cnt) as avg_question_cnt
from user_profile
group by university
order by avg_question_cnt asc;
分组排序练习题
https://www.nowcoder.com/practice/e00bbac732cb4b6bbc62a52b930cb15e
//平均值avg,按学校分组,按平均发帖数升序排列
select university,
avg(question_cnt) as avg_question_cnt
from user_profile
group by university
order by avg_question_cnt asc;
相关推荐