SQL Server Isolation Levels in a Nutshell

Tags: SQL

Here are the SQL Server Isolation Level in brief.

Read Uncommitted

Dirty reads. No locks are engaged so you can read data while it’s changing due to some other transaction.

Read Committed

You will only get committed data. So you only get data before or after any transactions. No dirty data.

Repeatable Read

Within a transaction, the same read query will return the same results, unless a new row is added. Updates have to wait until the reads are complete.

Serializable

Within a transaction, the same read query will return the same results, even if a new row is added. Updates and inserts have to wait until the reads are complete.

Snapshot

Same as serializable except updates and inserts do NOT have to wait until the reads are complete. The read is stored in tempDB.

There you go.  Wasn't that quick?

No Comments

Add a Comment