Hi
I ran into a problem concerning keeping an Oracle connection open.
I create a DataAccessAdapter object, setting the KeepConnectionOpen property to be true.
I then perform many save actions in the following way:
StartTransaction
SaveEntity
UpdateEntitiesDirectly
.
.
.
Commit;
.
.
ExecuteActionQuery
.
.
SaveEntity
.
.
GetScalar
.
.
StartTransaction
SaveEntity
UpdateEntitiesDirectly
.
.
.
Commit;
.
.
ExecuteActionQuery
.
.
For several months it has been working fine - the connection was always open, as expected, but lately I've made a change - I started using ODP directly (with the same connection that the adapter uses, got it by GetActiveConnection) - OracleCommand.ExecuteNonQuery instead of ExecuteActionQuery.
So eventually in my heavy scenario I use the adapter's connection not only for adapter's actions, but also for actions that cannot be performed by the adapter (DDL), and I don't see a problem with that.
Anyhow, since the change, actions like GetScalar closes the connection, as the KeepConnectionOpen property changes to false a little before, and an exception is raised when trying to perform the first action comes right after GetScalar.
I can't see how the change I've made causes the problem, I'll appreciate any help.