Answered step by step
Verified Expert Solution
Question
1 Approved Answer
SQL Create the following table: greate table audit emp aation varchar? (20), date asti date default sysdate) Create the following trigger: CREATE OR REPLACE TRIGGER
SQL
Create the following table: greate table audit emp aation varchar? (20), date asti date default sysdate) Create the following trigger: CREATE OR REPLACE TRIGGER audit e AFTER DELETE ON employees For EACH ROW BEGIN IE DELETING THEN INSERT INTO audis emp VALUES (USER 'DELETE' SYSDATE) END IF END: Modify the trigger and test: Perform the following: . Now modify the trigger to include an audit trail in case the employees table is changed with an UPDATE or INSERT, (Hint: you may want to use the conditional predicates INSERTING or UPDATING). Once you have made your changes test by (1) adding a new employee, (2) then make a change to the employee you added and (3) finally deleting the employee you added. . . Use a SELECT statement to display the contents of the audit emp tableStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started