トリガーの下に書き込んで wokson_staff テーブルにいくつかの制約を適用しようとしていますが、次のエラーが発生します:
PLS-00103: 次のいずれかを想定しているときに、シンボル「選択」が発生しました:
(-+case mpd mew mot null.....)
トリガーの何が問題なのかを理解するのを手伝ってくれる人はいますか?
ありがとう
Create or replace trigger Emp_cons
Before Insert on WorksON_Staff
For each row
begin
where exists( SELECT worksON_staff.AssignmentNo, worksON_staff.StaffNo,
staff.stafftype
FROM worksON_Staff,staff,workassignment
WHERE worksON.assignmentNo=worksON_staff.assignmentNo
and staff.staffNo=worksON_staff.staffNo
and
staff.stafftype ='supervisor'
INTERSECT
SELECT worksON_staff.AssignmentNo, worksON_staff.StaffNo,staff.stafftype
FROM worksON_Staff,staff,workassignment
WHERE
worksON.assignmentNo=worksON_staff.assignmentNo
and staff.staffNo=worksON_staff.staffNo
and
staff.stafftype ='authorizer')
Then raise_error('71001', 'blahblablah');
end Emp_cons;