查询每门课的平均分,并将平均分大于80分的显示输出Selectavg(grade)fromscgroupbycno()avg(grade)>=80
举一反三
- 查询每门课的平均分Selectcno,avg(grade)from()groupbycno
- 查询001号学生选课成绩的平均分,总分,最高分,最低分Selectavg(grade),()(grade),max(grade),min(grade)fromscwheresno=’001’
- SELECT ... WHERE Grade >=(SELECT AVG(Grade)FROM ...查询是大于课程平均成绩的_______同学。 A: 任何 B: 某位 C: 所有 D: 当前
- 查询最低成绩大于85分的学生学号和平均成绩,可以使用的查询语句是: 。 A: SELECT Sno, AVG(Grade) FROM SC HAVING MIN(Grade) > 85 GROUP BY Sno; B: SELECT Sno, AVG(Grade) FROM SC GROUP BY Sno HAVING MIN(Grade) > 85; C: SELECT Sno, AVG(Grade) FROM SC WHERE MIN(Grade) > 85 GROUP BY Sno; D: SELECT Sno, AVG(Grade) FROM SC GROUP BY Sno WHERE MIN(Grade) > 85;
- 按照学号进行分组,统计学生的平均成绩,且平均分按降序排列 A: select sid, avg(grade) from sc group by sid order by avg(grade) desc B: select sid, avg(grade) from sc group by cid order by avg(grade) desc C: select sid, avg(grade) from student group by sid order by avg(grade) desc D: select sid, avg(grade) from student group by cid order by avg(grade)