SQL For .NET Programmers

Is now available as an eBook for your Kindle reader.

Get it at Amazon today!

Recent Posts
Calendar
April 2009
S M T W T F S
« Mar   May »
 1234
567891011
12131415161718
19202122232425
2627282930  

Archive for April 15th, 2009

SQL – Transactions

food-frveg-017

Ruth ask,

How do I do transaction tracking within a stored procedure?

Hopefully, if you’ve been programming for any length of time against databases, you know that if you are updating multiple records in a database, you need to supply some sort of transaction tracking so that it either all works or all fails.

You do know that, right?

Well, maybe we should cover that in a future post.

But today, what happens if you have a stored procedure that updates multiple records in the database?  I can’t depend on the programmer to implement transaction tracking because all he sees is one call.  How is he supposed to know that it’s updating multiple records and should turn on transaction tracking in his code?

Read the rest of this entry »