??group by sno
??having count(distinct cno)>=2)
??3,即学过1号课程有学过2号课所有学生的姓名。
??select sname from s where sno in (select sno from sc where cno = 1 and sno in (select sno from sc where cno = 2)) ??
??group by sno
??having count(distinct cno)>=2)
??3,即学过1号课程有学过2号课所有学生的姓名。
??select sname from s where sno in (select sno from sc where cno = 1 and sno in (select sno from sc where cno = 2)) ??