question

Tom Staab avatar image
Tom Staab asked

Which row-versioning transaction isolation level do you use?

SQL Server 2005 and 2008 support 2 types of row-versioning transaction isolation levels.

  1. Snapshot Isolation
  2. Read Committed isolation with Row-Versioning

For information on the differences between the two, read this previous Q&A:
http://ask.sqlservercentral.com/questions/864/what-is-snapshot-isolation

If you have used one of these types, which one did you use and why did you choose that option over the other one?

I realize this is more of a forum question (no single right answer), but I think it will be informative and is a good extension to some of the other questions asked previously. Thanks.

sql-server-2008sql-server-2005transactionisolation-levelrow-versioning
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Grant Fritchey avatar image
Grant Fritchey answered

We're using READ COMMITTED SNAPSHOT because it provides just about everything we want without requiring our developers to make a single bit of change to their code. That's a pretty major win for us. Also, because it's a database setting as opposed to a connection setting we don't have to sweat the loss of remote transactions.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Tom Staab avatar image
Tom Staab answered

We used read committed isolation for 2 reasons:

  1. We didn't have to change existing queries that already used read committed isolation.
  2. It is recommended by Microsoft for most situations.

Once we switched this option on, we saw a dramatic reduction in ASP.NET page timeouts that had been occurring due to blocking.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Matt Whitfield avatar image
Matt Whitfield answered

In my last job we used SNAPSHOT, purely for the transactional consistency. We also saw a massive reduction in locks when moving from READ COMMITTED (without row versioning) to SNAPSHOT.

tempdb usage and bandwidth was not an issue for us, however, if it was, we would have considered READ COMMITTED with row versioning in order to reduce that load slightly.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Håkan Winther avatar image
Håkan Winther answered

We used READ COMMITTED with row versioning enabled in our large billing system (with a couple of hundreds of millions of records) and successfully reduced the locks and increased the concurrency. It was a quick and easy way of solving the issues, without any code changes.

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

David Wimbush avatar image
David Wimbush answered

Yep, read committed with row-level versioning. No application changes necessary and it works like a charm. I was concerned about the impact on tempdb but it hasn't got that big and doesn't seem to be under stress. (And that's on virtualised RAID 5 on a virtual machine - damn, I'm looking forward to our new hardware!)

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.