Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
TransactionScope and SQL Server Locks
Message
 
To
10/04/2012 11:16:55
General information
Forum:
ASP.NET
Category:
Databases
Miscellaneous
Thread ID:
01540816
Message ID:
01542139
Views:
45
Likes (1)
>
>Gary says that we don't even need to use TransactionScope at all ... and he's probably correct about that. We don't really care about the SELECTs being in a Transaction at all. I think I may have done that initially since we've wrapped all our other DataAccess (against our own databases) within TransactionScopes, but perhaps we don't need it for SELECTs against our customer's database. However, even if I don't use TransactionScope in my C# code, SQL Server wraps up each of my SELECT calls in an implicit transaction anyway ... and I think the default Isolation Level there is Serializable when not specified in the SqlConnection, so if I'm going to need to change it anyway, I might as well just do it within a TransactionScope. I think Serializable will use shared locks too, right?
>

I ran across this post this morning:

http://blogs.msdn.com/b/dbrowne/archive/2010/06/03/using-new-transactionscope-considered-harmful.aspx
-Paul

RCS Solutions, Inc.
Blog
Twitter
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform