October 29, 2008 at 7:45 pm
Hi,
I have a trigger on Update of Field1 and I would like to find out the value of Field2 for the Updated row.
Does anyone know how to do this, or know the SQL command for this. I am new to SQL programming.
Thanks
P.S I have looked on the net and found that some use 'Inserted' to refer to an Inserted Record. I have tried referring to the row as 'Updated' but that does not work.
October 29, 2008 at 8:06 pm
Hi,
Please ignore this post. I have used 'Inserted' and it seems to work.
Thanks
October 30, 2008 at 7:03 am
If you are new to SQL and triggers I would recommend you read this article so you avoid some common mistakes made in triggers: http://www.sqlservercentral.com/articles/Triggers/64214/
Jack Corbett
Consultant - Straight Path Solutions
Check out these links on how to get faster and more accurate answers:
Forum Etiquette: How to post data/code on a forum to get the best help
Need an Answer? Actually, No ... You Need a Question
November 3, 2008 at 5:21 pm
Thanks Jack. The link was helpful.
November 4, 2008 at 5:41 pm
Great, I hope it helped you understand triggers better.
Jack Corbett
Consultant - Straight Path Solutions
Check out these links on how to get faster and more accurate answers:
Forum Etiquette: How to post data/code on a forum to get the best help
Need an Answer? Actually, No ... You Need a Question
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply