题解 | #分组排序练习题#

分组排序练习题

http://www.nowcoder.com/practice/e00bbac732cb4b6bbc62a52b930cb15e

SELECT
university,
AVG(question_cnt)
from user_profile
group by university
order by avg(question_cnt)

题目 要求求出每个大学的发帖的平均值,所以,我们先用group by 分组大学,然后,求出发帖平均值avg(question_cnt) 在利用order by 进行排序即可

全部评论

相关推荐

点赞 评论 收藏
分享
评论
2
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务