1. Lära sig
  2. /
  3. Courses
  4. /
  5. Building and Optimizing Triggers in SQL Server

Connected

exercise

Keeping a history of row changes

The Fresh Fruit Delivery company needs to track changes made to the Customers table.

You are asked to create a new trigger that covers any statements modifying rows in the table.

Instruktioner

100 XP
  • Create a new trigger called CopyCustomersToHistory.
  • Attach the trigger to the Customers table.
  • Fire the trigger when rows are added or modified.
  • Extract the information from the inserted special table.