View previous topic :: View next topic |
Author |
Message |
mfjude Beginner
Joined: 12 Jan 2006 Posts: 7 Topics: 3
|
Posted: Fri Feb 17, 2006 2:03 am Post subject: variables in linkage section |
|
|
I am analysing some client code.He has inserted variables in the linkage section but is not using them as parameters in procedure division using clause....Can these variables be used as simple working-storage variables now ? |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12372 Topics: 75 Location: San Jose
|
Posted: Fri Feb 17, 2006 4:58 am Post subject: |
|
|
mfjude,
No you CANNOT use the variables as working storage variables.
Kolusu _________________ Kolusu
www.linkedin.com/in/kolusu |
|
Back to top |
|
|
mfjude Beginner
Joined: 12 Jan 2006 Posts: 7 Topics: 3
|
Posted: Fri Feb 17, 2006 5:08 am Post subject: reply |
|
|
but some address is assigned to it in the pgm ? |
|
Back to top |
|
|
PaulPeplinski Beginner
Joined: 17 Feb 2006 Posts: 11 Topics: 3
|
Posted: Fri Feb 17, 2006 9:50 am Post subject: |
|
|
Linkage section definitions can be used in a program without being in the USING clause in one of the following ways:
Getmain and then (if needed) address the storage. This is seen more in CICS with the EX CICS GETMAIN SET(....) ...... END-EXEC.
Using the COBOL SET ADDRESS of .... TO ..... to "redefine" an area of storage. One place this could be handy would be to remap a CICS DFHCOMMAREA to some public copybook. (The alternative being to move DFHCOMMAREA to Working Storage layouts on entry and moving it back on exit). |
|
Back to top |
|
|
|
|