Menu

#22 COPY REPLACING error when using IN as replacemnt value

invalid
duplicate
nobody
None
5 - default
2016-06-03
2007-05-16
csaci
No

Several of our programs do a COPY ???? REPLACING 'XXX' BY IN.

When these programs are compiled the following error occurs.

CPBACH.cbl:199: Error: syntax error

Where line 198:199 is

   01  IN-RECORD.
       COPY CPWWPOST REPLACING 'POST' BY IN.

This syntax works on both z/OS and MicroFocus.

I'm thinking that since IN is a resevered word, it is being checked for when doing the replacing. Although, in this situation, IN is never used by itself in any of the fields once the copybook is expanded.

Discussion

  • Roger While

    Roger While - 2007-06-09

    Logged In: YES
    user_id=1138256
    Originator: NO

    Duplicate of 1720197

     
  • Simon Sobisch

    Simon Sobisch - 2016-06-03
    • status: closed --> duplicate
    • Group: --> invalid
    • Priority: 5 --> 5 - default
      Duplicate of [bugs:#23]
     

    Related

    Bugs: #23


    Last edit: Simon Sobisch 2016-06-03

Log in to post a comment.