Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
TransactionScope and SQL Server Locks
Message
From
10/04/2012 12:54:37
 
General information
Forum:
ASP.NET
Category:
Databases
Miscellaneous
Thread ID:
01540816
Message ID:
01540830
Views:
42
>>>I would use ReadUncommitted Transaction Isolation Level and don't use Transactions in your code at all (you don't need them for selects).
>>>
>>>I recommend these blog posts by Dmitri Korotkevich (new SQL Server MVP):
>>>http://aboutsqlserver.com/2011/09/28/locking-in-microsoft-sql-server-table-of-content/
>>>
>>>They explain all these things in relatively simple terms.

>>
>>Thanks Naomi, I'll read his blog. BTW, I'm not using any additional Transactions in code, just the TransactionScope.
>>
>>I also wondered about the Distributed Transaction question I asked:
>>
>>>>Complicating all this is the fact that most of our other Transactions to our own databases get elevated to Distributed Transactions at some point. I'm pretty sure that this would NOT apply to the above Transaction to our customer's database, since I've made it RequiresNew, but I don't know for sure as it would be called in the middle of a distributed transaction.
>>
>>Any comments about that?
>>
>>~~Bonnie
>
>I understood you're only doing select statements. Are your statements put in the middle of a bigger process that does updates across multiple databases?

Yes, that was stated in the last paragraph in my original post (what I quoted above). This is a new Transaction (TransactionScopeOptions.RequiresNew) ... therefore, I assumed that it would not be dragged into the ambient distributed transactions. Is this a valid assumption?

~~Bonnie
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform