Export (0) Print
Expand All
Expand Minimize

IsolationLevel Enumeration

Specifies the transaction locking behavior for the connection.

This enumeration has a FlagsAttribute attribute that allows a bitwise combination of its member values.

[Visual Basic]
<Flags>
<Serializable>
Public Enum IsolationLevel
[C#]
[Flags]
[Serializable]
public enum IsolationLevel
[C++]
[Flags]
[Serializable]
__value public enum IsolationLevel
[JScript]
public
   Flags
 Serializable
enum IsolationLevel

Remarks

The IsolationLevel values are used by a .NET Framework data provider when performing a transaction.

The IsolationLevel remains in effect until explicitly changed, but it can be changed at any time. The new value is used at execution time, not parse time. If changed during a transaction, the expected behavior of the server is to apply the new locking level to all statements remaining.

Members

Member name Description Value
Chaos

Supported by the .NET Compact Framework.

The pending changes from more highly isolated transactions cannot be overwritten. 16
ReadCommitted

Supported by the .NET Compact Framework.

Shared locks are held while the data is being read to avoid dirty reads, but the data can be changed before the end of the transaction, resulting in non-repeatable reads or phantom data. 4096
ReadUncommitted

Supported by the .NET Compact Framework.

A dirty read is possible, meaning that no shared locks are issued and no exclusive locks are honored. 256
RepeatableRead

Supported by the .NET Compact Framework.

Locks are placed on all data that is used in a query, preventing other users from updating the data. Prevents non-repeatable reads but phantom rows are still possible. 65536
Serializable

Supported by the .NET Compact Framework.

A range lock is placed on the DataSet, preventing other users from updating or inserting rows into the dataset until the transaction is complete. 1048576
Unspecified

Supported by the .NET Compact Framework.

A different isolation level than the one specified is being used, but the level cannot be determined. -1

Requirements

Namespace: System.Data

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework

Assembly: System.Data (in System.Data.dll)

See Also

System.Data Namespace

Show:
© 2014 Microsoft