Informix Error -11045: Driver's SQLSetConnectOption failed.
Cause and resolution
Driver's SQLSetConnectOption failed.
This Informix CLI error code is the same as SQLSTATE value IM006. The following functions can return this error code: SQLBrowseConnect(), SQLConnect(), and SQLDriverConnect(). The function called the driver version of SQLSetConnectOption(), which returned an error. The CLI driver does not return this error.
See the error message returned by SQLError in the szErrorMsg to describe driver specific SQLSTATE or error message if returned for other reasons.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-11045 fires when the driver manager's call to the driver's SQLSetConnectOption() returns
an error — per the official guidance, this is the same as SQLSTATE value IM006, returnable
by SQLBrowseConnect(), SQLConnect(), and SQLDriverConnect(); the CLI driver itself
does not return this error.
- A driver-specific failure setting a connect option during connection setup, per the official guidance — no further named detail.
Solutions / Resolution
- Call
SQLError()to retrieve the driver-specific SQLSTATE or error message, per the official guidance.
Examples
N/A
No specific triggering statement is documented beyond a driver-level
SQLSetConnectOption() failure.
Diagnostic Checks
- Call
SQLError()immediately after this error for the driver-specific cause.
Related Errors / Related Topics
- -11043 — "Driver's SQLAllocEnv failed." The same class of driver-manager-level setup failure, earlier in connection setup.
- -11044 — "Driver's SQLAllocConnect failed." The same class of driver-manager-level setup failure, earlier in connection setup.
The driver manager's call to the driver's SQLSetConnectOption() failed — call SQLError()
for the driver-specific detail.