Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
seyha_moth
Yak Posting Veteran
74 Posts |
Posted - 2007-05-09 : 23:37:42
|
Dear sir or madamI have a problem related to creating trigger in sqlserver 2000.I want to create trigger: CREATE TRIGGER trX_ExamScore ON tblX_ExamScore FOR INSERT,UPDATE,DELETE AS Wanted statementI want to write statement to control when: -User insert then it will insert to a table -User Delete then it will update to a table -User Update then it will insert to a tableI look forward to hearing from youThank you in advance!Best regard,seyha moth |
|
PeterNeo
Constraint Violating Yak Guru
357 Posts |
Posted - 2007-05-10 : 01:56:39
|
Check the topic "Using the inserted and deleted Tables" in BOLand use those tables for Inserting or Updating the values into the Tables.From BOL :When you set trigger conditions, use the inserted and deleted tables appropriately for the action that fired the trigger. |
 |
|
|
|
|