SQL关于not exists的理解
学生(学号,姓名,系别,年龄)
课程(课程号,课程名,学时)
选读(学号,课程号,成绩)
问题:检索选读全部课程的学生姓名
select 学生.姓名
from 学生
where not exists( select *
from 课程
where not exists( select *
from 选读
where 学号=学生.学号 and 课程号=课程.课程号));
这个怎么理解,怎么单独运行 select *
from 选读
where 学号=学生.学号 and 课程号=课程.课程号
得不出什么结果?