athuraliya
IS-IT--Management
I want to write a trigger to run on any insert or update so that whatever values inserted, a desired value should be entered to a particular coloumn.
Let's say my table is T1 and it has columns a(number),b(Text),c(DateTime) . I want the trigger force to take GETDATE() value for column c always(on any update or insert) The main problem I have is in the trigger, how do I refer to the record which is being updated or inserted?
Has any body an idea?
Thanks in advance
Let's say my table is T1 and it has columns a(number),b(Text),c(DateTime) . I want the trigger force to take GETDATE() value for column c always(on any update or insert) The main problem I have is in the trigger, how do I refer to the record which is being updated or inserted?
Has any body an idea?
Thanks in advance