So I’m trying out my first COBOL project in 30 years. I’m trying to use XCode with Zowe, have my main frame account all working but getting File Status 90 when trying to open my file. I have read up on getting the second byte of the file status as it gives more detail, but am not able to define that PIC X(2) in order to get that secondary information. Every attempt I get this error:
“FILE STATUS” data-name “WS-FILE-STATUS” was not defined as a
two-character item. The data name was discarded.
Since COMP-X isn’t available (which I saw in online examples), this was my last attempt:
01 WS-FILE-STATUS. 05 STATUS-KEY-1 PIC X. 05 STATUS-KEY-2 PIC X. 05 BINARY-STATUS REDEFINES STATUS-KEY-2 PIC 9(2) COMP-5.
Appreciate the help!