how to change isolation level?
问题 I am using EF 4.0, and I would like to use the isolation level serializable , because in a transaction I would like to block a register when is read. Well, in SQL Server I try to change the isolation level with this command: SET TRANSACTION ISOLATION LEVEL SERIALIZABLE; And in C# I use this code to try to block the register: using (var scope = new TransactionScope(TransactionScopeOption.Required, new TransactionOptions { IsolationLevel = System.Transactions.IsolationLevel.Serializable })) {