PSQL 7.94 and .NET transactions concurrency issue -
12-15-2004
, 05:35 PM
We found out that we cannot start OdbcTransaction with optimistic locking
from .NET apllication. Default behaviour seems to be pesimistic isolation
level. When we try to explicitly set connection to use isollation level for
optimistic locking, Pervasive ODBC driver returns error condition. MS states
that transactions in .NET are designed for optimistic locking, but it does
not work with PSQL.
Most probably it also causes strange behaviour with transactions - if
someone kills connection to PSQL in the middle of transaction (ie. through
PSQL monitor), it happens that .NET opens new connection and runs rest of
the code in out of transaction connection, so new changes are commited
immediately. When it comes to Commit statement it founds out that connection
is dead and reports exception, so first uncommited part of transaction is
rejected.
Damir Dadasoviæ |