View previous topic :: View next topic
|
Author |
Message |
vero123
New User
Joined: 10 Sep 2005 Posts: 4
|
|
|
|
Hi,
I'd like to know how to convert 9-digit packed decimal data into 16-digit
character data in E-COBOL.
I'd appreciate your reply in this regard.
Thanks |
|
Back to top |
|
|
mmwife
Super Moderator
Joined: 30 May 2003 Posts: 1592
|
|
|
|
I guess you know that a 9 DIGIT comp-3 (packed) variable is 5 BYTES long and a 16 DIGIT char variable is 16 BYTES long.
Given that:
Code: |
pd-9-digit pic S9(009) comp-3.
ch-16-digit pic S9(016).
move pd-9-digit to ch-16-digit |
There may be variations on this depending on what you're trying to accomplish. |
|
Back to top |
|
|
vero123
New User
Joined: 10 Sep 2005 Posts: 4
|
|
|
|
Thanks for your response |
|
Back to top |
|
|
|