SELECT * from SC LEFT JOIN (SELECT sid,AVG(score) 平均成绩 from SC GROUP BY SId ) t ON SC.SId = t.sid ORDER BY 平均成绩 DESC
本文来自博客园,作者:弩哥++,转载请注明原文链接:https://www.cnblogs.com/bangbangzoutianya/p/15163419.html