By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,756 Members | 1,760 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,756 IT Pros & Developers. It's quick & easy.

need urgent info regarding rollback

P: 9
I need to write a SP to decommission one of the value from all tables.but all the deletions need to be made at a time, if problems occurs at any delete statement all the previously deleted rows need to be ROLLBACK. Is there any way fro this.

Thanks in advance
Feb 27 '07 #1
Share this Question
Share on Google+
1 Reply

P: 13
Wrap everything in a BEGIN ATOMIC, that will cause the rollback to rollback every thing. Create a SQL EXCEPTION hander and in that do your rollback. any SQL inside the BEGIN ATOMIC will get rolled back
Mar 6 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.