Você não precisa chamar Rollback se usar using.
O Dispose da transação desfaz automaticamente se não houve commit.
using (var tx = context.Database.BeginTransaction())
{
// operações
tx.Commit();
}
Você não precisa chamar Rollback se usar using.
O Dispose da transação desfaz automaticamente se não houve commit.
using (var tx = context.Database.BeginTransaction())
{
// operações
tx.Commit();
}