Easysoft ODBC-ODBC Bridge

What does the OOB do if an application terminates abnormally?

Article:
00629
Last Reviewed:
28th October 2008
Revision:
2

If an application using the OOB client terminates abnormally e.g. the application seg faults or is interrupted with SIGINT, the socket connection to the OOB server will be closed by the operating system.

The OOB server spots the closed socket connection and attempts to tidy up the ODBC connection to the ODBC driver. It will loop through all connections created by that client and call SQLDisconnect for each one. If any fail to disconnect due to SQLSTATE 25000 (transaction in progress) the server will call SQLEndTran(SQL_ROLLBACK) i.e. it will attempt to roll back the transaction so the connection may be closed. All handles in the ODBC driver are freed with SQLFreeHandle.

As an example, if you had some Perl which ran through OOB to MS SQL Server and it turned off autocommit, updated a row in a table and then the perl was stopped (say you hit ctrl/c or whatever your interrupt key sequence is) before the transaction was committed the OOB server would roll back the updates so the connection to the ODBC driver could be closed.

NOTE:
The OOB Server only notices the disconnected client when the ODBC
Driver Manager and ODBC driver return from the last ODBC call. As a
result, if you execute a query which takes a long time and kill your
client application whilst the query is executing, the connection will
not be dropped by the server until the query has completed.

Applies To

Knowledge Base Feedback

* Did this content help you?
* Please select one option based on your first choice:

(* Required Fields)


Oracle is a registered trademark of Oracle Corporation and/or its affiliates.