Skip to content

Commit

Permalink
differentiate between different types of transactions when printing i…
Browse files Browse the repository at this point in the history
…so levels in verboseSqlFormatter
  • Loading branch information
yellis committed Jun 10, 2014
1 parent 5b73a3a commit 3519122
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,12 @@ public string FormatSql(string commandText, List<SqlTimingParameter> parameters,
buffer.AppendLine("-- Database: " + command.Connection.Database);
if (command.Transaction != null)
{
buffer.AppendLine("-- Transaction Iso Level: " + command.Transaction.IsolationLevel);
buffer.AppendLine("-- Command Transaction Iso Level: " + command.Transaction.IsolationLevel);
}
if (Transaction.Current != null)
{
// transactions issued by TransactionScope are not bound to the database command but exists globally
buffer.AppendLine("-- Transaction Iso Level: " + Transaction.Current.IsolationLevel);
buffer.AppendLine("-- Transaction Scope Iso Level: " + Transaction.Current.IsolationLevel);
}
buffer.AppendLine();
}
Expand Down

0 comments on commit 3519122

Please sign in to comment.