Max (case Arthur c. name when N 'language' then b.s core else null end) "[Chinese],"
Max (case Arthur c. name when N 'mathematics' then b.s core else null end) "[math],"
Max (case Arthur c. name when N 'English' then b.s core else null end) "[English],"
Cast (avg (b.s core) as a decimal (18, 2))
"average"The from Student a
Left the join SC b on a.S # #=b.S
Left the join Course on biggest c # #=Arthur c.
Group by # a.S, a.S name
The order by "average" desc
CodePudding user response:
The great god help explain theCodePudding user response:
The building Lord baidu transfer line column, should understand,