September 18, 2003 at 11:44 pm
Is there a way to exclude a t-sql statement from a transaction?
I have a stored procedure called from another programm.
The calling programm starts a transaction and roll it back if an error occurs.
My stored procedure consists of update statements and some audit code.
When the transaction is rolled back, my audit code is also rolled back.
Can I exclude my audit code from the transaction?
September 19, 2003 at 1:58 am
Not that im aware of. This is a fundamental requirement for transaction consistency.
Chris Kempster
Author of "SQL Server 2k for the Oracle DBA"
Chris Kempster
www.chriskempster.com
Author of "SQL Server Backup, Recovery & Troubleshooting"
Author of "SQL Server 2k for the Oracle DBA"
September 19, 2003 at 9:54 am
What about moving your audit code to just after the transaction. This way you it is not rolled back if a problem arises. But, on a different track, if a transaction was rolled back, why do you want to keep the audit trail of something that does not exist?
Dave
Viewing 3 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply