Informix Error -11305: SQLGetTypeInfo supported for FORWARD_ONLY Cursors
Cause and resolution
SQLGetTypeInfo supported for FORWARD_ONLY Cursors
This Informix ODBC error code is the same as SQLSTATE value S1000. The following function can return this error code: SQLGetTypeInfo.
Change your cursor type to SQL_CURSOR_FORWARD_ONLY.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-11305 fires when SQLGetTypeInfo is called on a cursor type other than forward-only — per
the official guidance, this is the same as SQLSTATE value S1000.
- The current cursor type not being
SQL_CURSOR_FORWARD_ONLY, per the official guidance — the direct, only cause.
Solutions / Resolution
- Change your cursor type to
SQL_CURSOR_FORWARD_ONLY, per the official guidance.
Examples
N/A
No specific triggering statement is documented beyond calling SQLGetTypeInfo on a
non-forward-only cursor.
Diagnostic Checks
- Check the current
SQL_CURSOR_TYPEsetting, and switch toSQL_CURSOR_FORWARD_ONLYbefore callingSQLGetTypeInfo.
Related Errors / Related Topics
- -11307 — "In SQLExtendedFetch, only SQL_FETCH_NEXT is supported for
SQL_SCROLL_FORWARD_ONLY cursors." The same forward-only-cursor restriction, applied to
SQLExtendedFetchrather thanSQLGetTypeInfo.
SQLGetTypeInfo requires a forward-only cursor type — set SQL_CURSOR_FORWARD_ONLY first.