Hi,
I need some clarification how MS-DTC will behave in scenario given below
1) I have more than one connection in within a transactionscope (Isolation level - ReadCommited),which will bring MS- DTC into action now :
a) Will MS-DTC automatically change isolation level to SERIALIZABLE.
b) (Imp) If above answer is yes and I have implemented Row versioning based isolation level i.e. in addition to TransactionScope, i have also enabled the READ_COMMITTED_SNAPSHOT database option "ON", will it remain in effect means will it support "SERIALIZABLE" isolation level.
void OuterMethod() {
TransactionOptions tso = new TransactionOptions();
tso.IsolationLevel = System.Transactions.IsolationLevel.ReadCommitted;
using (TransactionScope tx = new TransactionScope(TransactionScopeOption.RequiresNew, tso)) {
InnerMethod("select * from testtable");
InnerMethod("update testtable set col1 = N'new value'");
tx.Complete();
}
}
static void InnerMethod(string sqlText) {
using (SqlConnection conn = SqlConnection(connStr)) {
conn.Open();
SqlCommand cmd = conn.CreateCommand();
cmd.ExecuteNonQuery();
}
}
Thanks