Answered step by step
Verified Expert Solution
Question
1 Approved Answer
0 0 1 CREATE the following tables - a. Dept triggers - Add Identity Column (1000,1) b. Emp triggers-Add Identity Column (1000,1) c. Emphistory
0 0 1 CREATE the following tables - a. Dept triggers - Add Identity Column (1000,1) b. Emp triggers-Add Identity Column (1000,1) c. Emphistory dbo.emp_triggers Columns empid (PK, int, not null) empname (varchar(50), null) deptid (int, null) Keys dbo.emphistory Columns empid (int, null) deptid (int, null) isactive (int, null) Keys Constraints TRIGGERS a. Trigger 1 - Build a trigger on the emp table after insert that adds a record into the emo. History table and marks IsActive column to 1 b. Trigger 2 - Build a tirnner on the emp table after an update of the empname or deptid column - It updates the subsequent empname and/or deptid in the emo history table. c. Build a trigger on the emp table after delete that marks the isactive status = 0 in the emo History table.
Step by Step Solution
★★★★★
3.39 Rating (168 Votes )
There are 3 Steps involved in it
Step: 1
To achieve the described database structure and triggers we will create the necessary tables Dept Emp and Emphistory with the specified column definit...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