Question: Create a trigger on the Employee table so that before an employee s supervisor is updated, we check that the new supervisor isn t being

Create a trigger on the Employee table so that before an employees supervisor is
updated, we check that the new supervisor isnt being supervised by this employee. If the new
supervisor is supervised by the employee, set the new supervisors supervisor to null.
E.g. Suppose Alice is supervised by Bob. If we were to set Bobs supervisor to Alice, then we
should set Alices supervisor to null.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!