View previous topic :: View next topic
|
Author |
Message |
p.anbuselvan
New User
Joined: 09 Jun 2008 Posts: 6 Location: India
|
|
|
|
Hi All,
My requirement to unload a table data in readable format. I have handles few datatypes. Problem with Decimal fields.
I tried with DIGITS. It is showing in readable but without decimal point.
If the value is 123.45, same should be populated while unloading.
Utility used : INZUTILB
Tried with DECIMAL EXTERNAL keyword -> Seems not supported.
Appreciate your help ! |
|
Back to top |
|
|
Marso
REXX Moderator
Joined: 13 Mar 2006 Posts: 1353 Location: Israel
|
|
|
|
Hello and Welcome to the Forum.
You can try to select the column as CHAR(MY_COLUMN) or LPAD(MY_COLUMN,15)
(NB. LPAD returns a varchar) |
|
Back to top |
|
|
Rohit Umarjikar
Global Moderator
Joined: 21 Sep 2010 Posts: 3076 Location: NYC,USA
|
|
|
|
Run DSNTEP2 which automatically expand all the columns to readable format. But the only problem with this is the LRECL is limited to 133 bytes. so the output will will span multiple lines |
|
Back to top |
|
|
p.anbuselvan
New User
Joined: 09 Jun 2008 Posts: 6 Location: India
|
|
|
|
Thanks Marso.
CHAR(MY_COLUMN) works for me. |
|
Back to top |
|
|
p.anbuselvan
New User
Joined: 09 Jun 2008 Posts: 6 Location: India
|
|
|
|
When I am using CHAR(MY_COLUMN), seems first byte is reserved for sign.
When the value is negative, it shows '-' whereas spaces for positive value.
Is there any way to get '+' populated for positive values? |
|
Back to top |
|
|
|