Informix Error -22207: Host variables may only be 01-49 or 77 level.
Cause and resolution
Host variables may only be 01-49 or 77 level.
ESQL/COBOL supports only level 01 through level 49 COBOL variables and record types, plus COBOL variable level 77 if your COBOL compiler supports it. Check the level number of the host variable to see if it is valid.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-22207 fires when a host variable/record uses a COBOL level number ESQL/COBOL doesn't support — per the official guidance, only levels 01-49 are supported, plus level 77 if the COBOL compiler supports it.
- A host variable declared at a level outside 01-49 (or 77, if the compiler supports it), per the official guidance — the direct, only cause.
Solutions / Resolution
- Check the level number of the host variable and correct it to a supported level, per the official guidance.
Examples
N/A
No specific triggering statement is documented beyond an unsupported level number.
Diagnostic Checks
- Check the flagged host variable's declared level number, and correct it to 01-49 (or 77 if supported).
Related Errors / Related Topics
No closely related error codes are cross-referenced for -22207 in this set yet.
A host variable was declared at an unsupported COBOL level — use level 01-49 (or 77 if the compiler supports it).