Informix Error -22233: compiler-name does not allow array elements to be passed as parameters.
Cause and resolution
compiler-name does not allow array elements to be passed as parameters.
Unless you are using either the Ryan McFarland RM/COBOL 85 compiler or the Micro Focus COBOL/2 compiler, you cannot pass array elements as parameters. Use one of the specified compilers, or rewrite this section of code that involves arrays.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-22233 fires when array elements are passed as parameters using a COBOL compiler that doesn't allow it — per the official guidance, only the Ryan McFarland RM/COBOL 85 compiler or the Micro Focus COBOL/2 compiler support this.
- Passing array elements as parameters with a compiler other than RM/COBOL 85 or Micro Focus COBOL/2, per the official guidance — the direct, only cause.
Solutions / Resolution
- Use RM/COBOL 85 or Micro Focus COBOL/2, per the official guidance, or
- Rewrite the code section involving arrays to avoid passing elements as parameters, per the official guidance.
Examples
N/A
No specific triggering statement is documented beyond passing array elements as parameters on an unsupported compiler.
Diagnostic Checks
- Check which COBOL compiler is in use, and either switch to a supported one or rewrite the array-parameter code.
Related Errors / Related Topics
- -22227 — "Invalid COBOL compiler compiler-name." A related compiler-support error, on the compiler being entirely unsupported rather than lacking this specific feature.
Array elements were passed as parameters on a compiler that doesn't support it — use RM/COBOL 85, Micro Focus COBOL/2, or rewrite the code.