Page 1 of 1

Problem with TransactionScopeOption.Suppress

Posted: Mon 03 Oct 2011 15:20
by JORGEMAL
I am using the System.Transactions Namespace but I need one table operation out of the transaction, so I defined a TransactionScope for it and set its TransactionScopeOption parameter to "Suppress" but it seems it does not work. Such a table is a PostgreSQL table used to insert logging data. I am throwing an exception in order to test this situation. After the process is finished, the tables involved in the transaction do not contain any records and the logging table does not have any new record added either. The logging table inserts a new record everytime an exception is thrown. Is there any issue supporting TransactionScopeOption.Suppress?
I am using dotConnect for PostgreSQL v5.10.111.0 and PostgreSQL v9.0.

Regards,
Jorge Maldonado

Posted: Fri 07 Oct 2011 12:59
by Shalex
Make sure that you call TransactionScope.Complete() before disposing your global transaction.

If this is not the case:
1) send us a small test project with the corresponding DDL/DML script to reproduce the issue in our environment;
2) is there any exception on disposing your TransactionScope?
3) does transaction work properly when there is no suppressed code?
4) does the problem persist with the latest (5.50.228) build of dotConnect for PostgreSQL?

We cannot reproduce the issue at the moment.

Posted: Fri 07 Oct 2011 16:31
by JORGEMAL
MY BIG MISTAKE !!!
There was a syntax error I had not detected and it was causing the TransactionScopeOption.Suppress failure.
I apologize for any inconvenience this might have cause.

Respectfully,
Jorge Maldonado