USE THE AdventureWorks2012 database to answer the
question
4. Complete the following queries as a batch. Make sure the check if the trigger already exists. If so, drop it first. a. Write a query that creates a FOR trigger (Human Resources. TriggerCheckModifedDate) that checks the modified date. It ensures that during the insert of a new department, the modified date is the current day. If it is not, the row is updated, setting ModifiedDate to the current date and time. The trigger uses the Human Resources Department table in AdventureWorks 2012 database. (15 points) Command(s) completed successfully. b. Insert the following row to the Human Resources Department table: (Information Systems', 'Operations', '12/05/2016'). Retrieve the modified record from the table. Your table should show today's date and time in the record. (5 points) Information Systems Operations 2017-11-30 14:57:59.990
USE THE AdventureWorks2012 database to answer the question
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am