select * from 敏仔喊student 桥野where sno in
(select s.sno 戚禅from
(select sno,row_number() over(partition by ssex order by degree desc) rn
(select a.sno,a.ssex,sum(b.degree) degree
from student a,Score b where a.sno=b.sno
group by sno,ssex) t) s
where rn=1)