FYI,
  There are ways that one can "sort-of" get around this (well-documented)
restriction by using the REPLACE statement rather than the REPLACING phrase
of the COPY statement, but these can complicated and error-prone.

"Phillips, Thomas" <[EMAIL PROTECTED]> wrote in message
news:<[EMAIL PROTECTED]
p.principal.com>...
> From the COBOL Language Reference:  "COPY statements can be nested.
> However, nested COPY statements cannot contain the REPLACING phrase, and
> a COPY statement with the REPLACING phrase cannot contain nested COPY
> statements."
> 
> What you're trying to do is not allowed by the compiler.  
> 
> 
> -----Original Message-----
> From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED]
> Behalf Of Amlan Prasad
> Sent: Thursday, April 12, 2007 6:42 AM
> To: [EMAIL PROTECTED]
> Subject: Expanding Copybook inside Copybook
> 
> Hi,
> 
> I have a copybook inside a copybook. The first copybook is using COPY
> option 
> with REPLACE. The inside copybook is not getting expanded during
> compilation 
> and hence I am getting compile errors.
> Is there any option to expand all the nested copybooks.
> 
> Thanks,
> Amlan

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to