View previous topic :: View next topic
|
Author |
Message |
Neena John
New User
Joined: 20 Nov 2008 Posts: 13 Location: bangalore
|
|
|
|
Hi all,
There is a requirement of converting a packed decimal to readable format to write to an output file.
The input variable is in format as follows.
01 ws-inp-amt pic s9(12)v9(2) comp -3.
So the corresponding output variable declaration is as follows
01 ws-out-amt pic +z(12)9.99.
If the input value is +1234.99, the output coming now is
There is a space appearing between the sign and the value.But the desired result is that the sign should come immediately
before the value +1234.99.
How to remove the spaces appearing between the sign and the value
without modifying the variable length? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
Back to top |
|
|
Neena John
New User
Joined: 20 Nov 2008 Posts: 13 Location: bangalore
|
|
|
|
Thanks a lot.
I used ++(12)9.99 instead of +z(12)9.99.Now the sign is coming immediately after the value. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Good to hear it is working - thank you for letting us know
d |
|
Back to top |
|
|
|