Informix Error -11415: Cannot set LO Automatic option OFF when Standard ODBC Types only is ON.
Cause and resolution
Cannot set LO Automatic option OFF when Standard ODBC Types only is ON.
This Informix ODBC error code is the same as SQLSTATE value S1000. The following functions can return this error code: SQLSetStmtAttr and SQLSetConnectAttr.
Turn the SQL_INFX_ATTR_ODBC_TYPES_ONLY off first before turning the SQL_INFX_LO_AUTOMATIC_ATTR off for a statement or connection.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-11415 fires when turning off SQL_INFX_LO_AUTOMATIC_ATTR while
SQL_INFX_ATTR_ODBC_TYPES_ONLY is still on — per the official guidance, this is the same
as SQLSTATE value S1000, returnable by SQLSetStmtAttr and SQLSetConnectAttr.
SQL_INFX_ATTR_ODBC_TYPES_ONLYstill on while attempting to turn offSQL_INFX_LO_AUTOMATIC_ATTR, per the official guidance — the direct, only cause; the two attributes have a dependency order.
Solutions / Resolution
- Turn
SQL_INFX_ATTR_ODBC_TYPES_ONLYoff first, per the official guidance, before turningSQL_INFX_LO_AUTOMATIC_ATTRoff.
Examples
N/A
No specific triggering statement is documented beyond turning the attributes off in the wrong order.
Diagnostic Checks
- Check the current state of both
SQL_INFX_ATTR_ODBC_TYPES_ONLYandSQL_INFX_LO_AUTOMATIC_ATTR, and set them in the required order.
Related Errors / Related Topics
- -11416 — "Cannot set Standard ODBC Types only to ON when LO Automatic option is OFF." The mirror-image ordering restriction, for turning the attributes on rather than off.
- -11422 — "Smart large objects can only be used by setting SQL_INFX_ATTR_LO_AUTOMATIC." A related restriction on the same attribute, about it being required for smart-large-object use at all.
SQL_INFX_LO_AUTOMATIC_ATTR can't be turned off while SQL_INFX_ATTR_ODBC_TYPES_ONLY is
still on — turn that one off first.