Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Cobol Physical Address identification of variable.

Status
Not open for further replies.

Challakk

Programmer
Apr 11, 2006
2
US
My Requirement is...
Example of my requirement is:

01 ABC pic X(1).
01 XYZ Pic X(1).

Procedure Division.
move '1' to ABC.

Move 'ABC' to XYZ.

.....Unknown code here.....

Display XYZ.

Stop run.

My question is, is it possible to get the Display statement to Display the value of '1' instead of 'ABC'.


Please let me know.

Thanks for your help in advance.
Challakk.
 
Replace this:
Move 'ABC' to XYZ
with this:
Move ABC to XYZ

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
I know that if you pass the variable ABC to XYZ this is possible ..but My requirement is to convert the Sting value 'ABC' into the variable ABC inside the program.

hope this clarifies the wuestion.

Thanks anyways for your reply.
Challakk.
 
The short answer is, "No."

COBOL does have pointers, and one could accomplish a 'work-alike' by the use of pointers for a very limited situation. Not recommended.

So, rather than stop with this answer, perhaps you would like to explain to the group what you are trying to do, rather than how you are trying to do it. Perhaps then we can be helpful.

Tom Morrison
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top