A
Allan Ebdrup
I'm using dotNet 2.0 and System.Transactions to run transactions that span
multiple database queries, Now I would like to log any Sql errors that occur
in the transaction, but when I insert the logentry into the database the
query that does the inserting is automatically enlisted in the running
transaction and rolled back when the transaction aborts.
How do I run the query inserting into the log outside the current
transaction, so that it is not rolled back with the current transaction?
I'm guessing I create a new transaction scope that doesn't enlist in the
current transaction, is this correct? And if so, how do I do it?
Kind Regards,
Allan Ebdrup
multiple database queries, Now I would like to log any Sql errors that occur
in the transaction, but when I insert the logentry into the database the
query that does the inserting is automatically enlisted in the running
transaction and rolled back when the transaction aborts.
How do I run the query inserting into the log outside the current
transaction, so that it is not rolled back with the current transaction?
I'm guessing I create a new transaction scope that doesn't enlist in the
current transaction, is this correct? And if so, how do I do it?
Kind Regards,
Allan Ebdrup