Hello,
We have an application that should not be allowed to reconnect to the DB in some cases. This worked fine in dbExpress 3 drivers but doesn't in the 4.x drivers.
This is the scenario:
1. Create application that opens connection to the db with the dbexpsda.dll
2. Execute a select query from inside the application
3. From outside source (like MS Query analyzer) kill the connection with the 'KILL ###' command
4. Execute 'select' query from the application will give error - this is good but in the 4.x drivers will auto reconnect after this error and in 3.x will not reconnect
5. Execute another 'Select' query - in 4.x will work and in 3.x will give another error.
we want to mimic the 3.x behavior that doesn't reconnect,
what can be done?
Disable auto reconnect
Thanks for the fast reply,
We need this option to control user login from multiple processes,
We use the 'KILL SPID#' to disconnect users
As I have explained it worked great with the older drivers.
when we upgraded to newer drivers it stopped working.
We need an option to make connection stay disconnect if an error occurs.
Trying to use the OnDisconnect event didn't work as it only fires the event when the connection is being closed by the 'Close()' method and not when an exception was raised.
We need this option to control user login from multiple processes,
We use the 'KILL SPID#' to disconnect users
As I have explained it worked great with the older drivers.
when we upgraded to newer drivers it stopped working.
We need an option to make connection stay disconnect if an error occurs.
Trying to use the OnDisconnect event didn't work as it only fires the event when the connection is being closed by the 'Close()' method and not when an exception was raised.