我收到一条错误消息,说明缺少正确的括号。它希望我在使用except运算符
之前先在where子句中关闭my not exists语句我的代码:
select S.ID, S.SNAME
from ENROLLMENT E, STUDENT S
where E.STUDENT = S.ID and E.COURSENUM = 310 and E.DEPT = 'MATH'
intersect
select S2.ID, S2.SNAME
from STUDENT S2
where not exists(
select P.PCOURSENUM, P.DEPT
from PREREQUISITE P
where P.COURSENUM = 310 and P.DEPT = 'MATH'
except
select T.COURSENUM, T.DEPT
from TRANSCRIPT T
where T.STUDENT = S2.ID
)