Thursday, March 8, 2012

code needed for a trigger

Does anyone have code for a trigger that when the user deletes the record trigger it to insert into another table? Thanks in advance and appreciate your help!I cant "write" code for you but I can steer in you in the right direction

you can do a


DECLARE @.var1 ..., @.var2...
SELECT
@.var1=Col1
@.var2=Col2
...
FROM
DELETED

INSERT INTO <table> <cols> VALUES (@.var1, @.var2...)

|||I am sorry but i am really unfamiliar with the trigger functions. So if anyone can help i would appreciate it.|||Check out the DELETE TRIGGER portion of this article:Auditing Through Triggers.

Terri|||Exactly what i needed. Thank you very much!

No comments:

Post a Comment