Informix Error -6045: No column or index has been selected.
Cause and resolution
No column or index has been selected.
Before the program calls dbfind(), it must call dbselfield() to establish a retrieval method even if no index is to be used. Review the program logic to make sure that this action is performed.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-6045 fires when dbfind() is called before dbselfield() has established a retrieval method — per the archived catalogue, dbselfield() must be called even when no index is actually used.
- dbfind() called before dbselfield() established a retrieval method, per the archived catalogue — the direct, only cause.
Solutions / Resolution
- Call dbselfield() before dbfind(), per the archived catalogue, even when no index is used.
Examples
N/A
No specific triggering statement is documented beyond the function-level condition described above.
Diagnostic Checks
- Confirm dbselfield() precedes the dbfind() call.
Related Errors / Related Topics
- -6016 — "No view has been set."
- -6019 — "No view has been set."
- -6029 — "No view has been set."
Call dbselfield() to establish a retrieval method before dbfind(), even without an index.