all groups > sql server programming > november 2005 >
You're in the

sql server programming

group:

Result of a transaction???


Result of a transaction??? Chakkaradeep
11/16/2005 10:26:04 PM
sql server programming: hi all,

am new to SQL Server Programming, i want to get the result of a transaction
whether successful or not, so that i can commit transaction continue to the
next transaction, how could i do this in SQL Server?...

regards,
Re: Result of a transaction??? Ben Nevarez
11/16/2005 11:02:00 PM

Wow, this one is not easy to explain in a single message. Read 'Transactions
(Database Engine) on Books Online (SQL Server 2005).

Basically you can use 'commit transaction' and 'rollback transaction' to do
just that, commit and rollback your transactions. But there is a lot more.

Ben Nevarez




[quoted text, click to view]

Re: Result of a transaction??? Tibor Karaszi
11/17/2005 12:00:00 AM
You need error handling. Do yourself a favor and take the time to read the two error handling
articles at www.sommarskog.se.

--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/


[quoted text, click to view]

Re: Result of a transaction??? Chakkaradeep
11/17/2005 1:10:02 AM
Hi Tibor,

thanks for the link, it really helped me and i got what i wanted :-)

Regards,
C.C.Chakkaradeep

[quoted text, click to view]
Re: Result of a transaction??? Tibor Karaszi
11/17/2005 11:07:09 AM
I'm glad it helped. Too often we see people skipping the basics, producing crappy code with bugs and
costing a fortune to maintain...
And, thanks goes to Erland for taking the time to write the articles and publish them.

--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/


[quoted text, click to view]

AddThis Social Bookmark Button