We are converting some GCOS (Bull) mainframe programs to work on a Microfocus platform. I have a lot of calls for this particular item.
The variable is defined as pic x, and 0 is moved to it, Alphanumeric check. But in the mainframe code (in lots of places) this value is checked against zero (the word, numeric value). In microfocus COBOL this is false, but in GCOS it is true. If I change this:
IF IN-STATUS NOT = ZERO GO TO 580-GET-OUT
to this:
IF IN-STATUS NOT = "0" GO TO 580-GET-OUT
it works in Microfocus (probably for GCOS too, I didn't specifically check). The second statement is true in GCOS.
Is there a setting for the program which will allow "0" to be checked against ZERO or 0?