View previous topic :: View next topic |
Author |
Message |
anita_m Beginner

Joined: 20 Sep 2006 Posts: 41 Topics: 12 Location: Venus
|
Posted: Mon May 21, 2007 1:09 pm Post subject: Copybook declaration working storage |
|
|
I have declared a copybook XXXPNAPS in the file section and also in the working storage in the following manner.
In data division
Code: |
FD REC-BASE.
COPY XXXPNAPS. |
In working storage
Code: |
COPY XXXPNAPS
REPLACING ==01 MY-RECORD.== BY
==01 WS-MY-RECORD.==
==M-== BY =WS-==. |
On compiling it gives following error for the declaration done in working storage.
Code: |
IGYDS0017-E "01" SHOULD BEGIN IN AREA "A". |
Following is what I found in the dump of compile job.
Looks like the whole copy book after 01 level variable has shifted by a few bytes when declared in working storage. I am unable to find the reason for this.
Code: |
---+----3----+----4----+----5----+----6----+----7----
COPY XXXPNAPS.
******************************************************
***** THIS IS TEMP BASE FILE COPYBOOK
******************************************************
01 MY-RECORD.
05 M-PROVIDER-KEY.
10 M-PROVIDER-ID PIC 9(7).
.
.
.
---+----3----+----4----+----5----+----6----+----7----+
COPY XXXPNAPS
REPLACING ==01 PROVIDER-RECORD.== BY
==01 WS-PROVIDER-RECORD.==
==M-== BY ==WS-==.
******************************************************
***** THIS IS TEMP BASE FILE COPYBOOK
******************************************************
01 WS-RECORD.
05 M-PROVIDER-KEY.
10 M-PROVIDER-ID PIC 9(7).
.
.
|
|
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
|
|
Back to top |
|
 |
vak255 Intermediate

Joined: 10 Sep 2004 Posts: 384 Topics: 79
|
Posted: Tue May 22, 2007 3:35 pm Post subject: |
|
|
I was looking exactly how to use 'REPLACE' in PL/1.....what is the corresponding key-word in PL/1. |
|
Back to top |
|
 |
kolusu Site Admin

Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
|
Posted: Tue May 22, 2007 3:45 pm Post subject: |
|
|
Quote: |
I was looking exactly how to use 'REPLACE' in PL/1.....what is the corresponding key-word in PL/1.
|
vak255,
1. Click on "Quick Manuals" link on top of this page
2. Click on "Enterprise PL/I Language Reference" under PL/I manuals section
3. Click on and type Replace and click on SEARCH
4. read the first hit you got
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
 |
vak255 Intermediate

Joined: 10 Sep 2004 Posts: 384 Topics: 79
|
Posted: Tue May 22, 2007 3:51 pm Post subject: |
|
|
Thanks Kolusu. I serached help boards but not PL/1 manual as I am not sure of the word i am suppose to search, when I saw this post...I could not resist typing here.
I appreciate your help. |
|
Back to top |
|
 |
Nic Clouston Advanced
Joined: 01 Feb 2007 Posts: 1075 Topics: 7 Location: At Home
|
Posted: Wed May 23, 2007 3:22 am Post subject: |
|
|
Note: the %REPLACE in PL/1 is was introduced in Version 3 (which is why I have not heard of it as we still run v2!) _________________ Utility and Program control cards are NOT, repeat NOT, JCL. |
|
Back to top |
|
 |
|
|