SQL Server - Transaction Isolation Levels - Asked By prathap chowdary on 05-Mar-12 03:09 AM

Hi This is Prathap......I want information of transaction isolation levels

When i am fire this query on sql server 2008

select * from sys.dm_exec_requests as req

cross apply sys.dm_exec_sql_text (req.sql_handle)

In result window one column is there name is transaction isolation level. In this column having 2 and some of rows having 3.

Please tell me what is the meaning of transaction isolation level 2 and 3 in this scenario.?

I know theritically like read committed and repetable read,serializable.......

Please give me the clarity any one.....

Thanks advance....


kalpana aparnathi replied to prathap chowdary on 05-Mar-12 03:13 AM

Use following links for understanding Transaction Isolation Levels:

Somesh Yadav replied to prathap chowdary on 05-Mar-12 03:41 AM
Hi prathap refer to the below link, explained very clearly about Transaction Isolation Levels with examples,


Hope it helps you.
prathap chowdary replied to kalpana aparnathi on 05-Mar-12 04:47 AM
Thanks Kalpana......

But i want the meaning of that query transaction isolation level=2 or 3 like

In servers where we can see the isolation levels.....
kalpana aparnathi replied to prathap chowdary on 05-Mar-12 04:54 AM
set transaction isolation level 3

Applications that use transaction isolation level 3 should set that isolation level at the beginning of each session. However, setting transaction isolation level 3 causes Adaptive Server to hold any read locks for the duration of the transaction. If you also use the chained transaction mode, that isolation level remains in effect for any data retrieval or modification statement that implicitly begins a transaction. In both cases, this can lead to concurrency problems for some applications, since more locks may be held for longer periods of time.

To return your session to the Adaptive Server default isolation level:

set transaction isolation level 2
or set transaction isolation level repeatable read

To enforce transaction isolation level 2 from a query, use:

select title_id, price, advance from titles at isolation 2


select title_id, price, advance from titles at isolation repeatable read

Transaction isolation level 2 is supported only at the transaction level. You cannot use the at isolation clause in a select or readtext statement to set the isolation level of a query to 2. http://manuals.sybase.com/onlinebooks/group-as/asg1250e/sqlug/@ebt-link;pt=53713?target=%25N%15_54131_START_RESTART_N%25