Is Explicit Transaction Rollback Necessary?
问题 Many examples out there advocate explicit rollback of database transactions, along the lines of: using (var transaction = ...) { try { // do some reading and/or writing here transaction.Commit(); } catch (SqlException ex) { // explicit rollback transaction.Rollback(); } } However, I tend to do this: using (var transaction = ...) { // do some reading and/or writing here transaction.Commit(); } When an exception occurs, I'm just relying on the implicit rolling back of transactions that aren't