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 |
|
senthil_nagore
Master Smack Fu Yak Hacker
1007 Posts |
Posted - 2009-06-03 : 02:48:53
|
| Hi all,Is it possible to get old and new record in after update trigger??If yes, please advice me!Senthil.C------------------------------------------------------[Microsoft][ODBC SQL Server Driver]Operation canceled |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2009-06-03 : 02:52:49
|
Yes.You have access to both the INSERTED and DELETED virtual tables. E 12°55'05.63"N 56°04'39.26" |
 |
|
|
senthil_nagore
Master Smack Fu Yak Hacker
1007 Posts |
Posted - 2009-06-03 : 02:55:23
|
| Hi peso,I'm relatively new to triggers, will u guide me with some examples?Senthil.C------------------------------------------------------[Microsoft][ODBC SQL Server Driver]Operation canceled |
 |
|
|
GilaMonster
Master Smack Fu Yak Hacker
4507 Posts |
Posted - 2009-06-03 : 02:59:05
|
| Check the entry in Books Online for CREATE TRIGGER. There are some examples there.--Gail ShawSQL Server MVP |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-06-03 : 12:31:13
|
quote: Originally posted by senthil_nagore Hi all,Is it possible to get old and new record in after update trigger??If yes, please advice me!Senthil.C------------------------------------------------------[Microsoft][ODBC SQL Server Driver]Operation canceled
if its sql 2005, you can also use OUTPUT operator to access INSERTED & DELETED tables to get old and new values. |
 |
|
|
|
|
|