Informix Error -22554: Field type field-type-name has been used out of context.
Cause and resolution
Field type field-type-name has been used out of context.
This error is generated when, for example, the field type TYPE is used where COUNT is expected. Check the syntax and usage for system-descriptor field names in the discussion of the ALLOCATE DESCRIPTOR and GET DESCRIPTOR statements in the IBM Informix Guide to SQL: Syntax. For a discussion of the system-descriptor area, see the manual for your embedded-language product.
Oninit® Troubleshooting Guidance
Reasons / Common Causes
-22554 fires when a system-descriptor field type is used where it doesn't
apply — per the official guidance, for example using TYPE where COUNT is expected.
- A system-descriptor field type used in the wrong context, per the official guidance — the direct, only cause.
Solutions / Resolution
- Check the syntax and usage for system-descriptor field names in the
ALLOCATE DESCRIPTOR/GET DESCRIPTORdiscussion of the IBM Informix Guide to SQL: Syntax, per the official guidance, and consult your embedded-language manual for the system-descriptor area.
Examples
N/A
No specific triggering statement is documented beyond a field type used out of context.
Diagnostic Checks
- Check the flagged field type against the
ALLOCATE DESCRIPTOR/GET DESCRIPTORsyntax reference, and correct the context it's used in.
Related Errors / Related Topics
- -22555 — "The type of host-variable does not match the expected type for this field." A related system-descriptor error, on a host variable's type mismatching a field rather than a field type used in the wrong context.
- -22559 — "SQLUNKNOWN is invalid data type, need to be set valid data type." A
related system-descriptor error, on an unresolved
SQLUNKNOWNtype fromDESCRIBE INPUTrather than a field used out of context.
A system-descriptor field type was used out of context — check the field-name syntax reference.