Hello everyone,
For the same ADO.Net statement, I want to make sure my understanding of isolation level and lock is correct.
In default SQL Server isolation level (read committed), after read each row, the row will unlocked;
If I raise isolation level to repeatable read, the lock (on the whole table? or some other level lock?) will be hold until the end of while loop?
e.g.:
SqlCommand cmd = conn.CreateCommand();
cmd.CommandText= "select operation_id, operation_code, product_id, quantity
from dbo.operations where processed=0";
reader=cmd.ExecuteReader();
while (reader.Read())
{
// some operations
}
thanks in advance, George