Question: SQL Insert of trigger. Create an INSTEAD OF trigger on INSERT Session Hours to enforce the rule that no tutor should work more than 60

SQL Insert of trigger.SQL Insert of trigger. Create an INSTEAD OF trigger on INSERT Session

Create an INSTEAD OF trigger on INSERT Session Hours to enforce the rule that no tutor should work more than 60 hours in a month. The logical steps before trying to actually write the trigger. It is easy to get confused if you don't have a clear recipe to follow: Get the date from the INSERTED table. Extract the month. Create a variable for the total hours. Assign to total the sum of each session for that month (assuming 30 minutes each). Check to see if the sum > 60 Check if it is output a message. Otherwise complete the insert into the Session table

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 Databases Questions!