PL/I · Exception

ONCODE 80: UNDEFINEDFILE

What does ONCODE 80: UNDEFINEDFILE mean in PL/I?

An OPEN failed for reasons the more specific file conditions do not cover, commonly a conflict between the attributes declared for the file and the attributes specified on the OPEN statement, or between those attributes and the physical dataset itself.

ONCODE 80: UNDEFINEDFILEIBM Enterprise PL/I for z/OS · PL/I for AIX

Condition

An OPEN failed for reasons the more specific file conditions do not cover, commonly a conflict between the attributes declared for the file and the attributes specified on the OPEN statement, or between those attributes and the physical dataset itself.

Fix

Use the ONFILE built-in function inside the ON-unit to get the name of the file variable involved, then compare its DECLARE attributes against both the OPEN statement and the dataset's actual attributes (record format, organization) for a mismatch.

Pending source verification. Not yet checked against official documentation.

Related exception