IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to Convert edited numeric to Packed Decimal Using Sort?


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
SathyaS

New User


Joined: 20 Sep 2005
Posts: 11

PostPosted: Tue May 08, 2007 11:07 pm
Reply with quote

Hi,
I have a input file which has an amount field in the edited numeric format ' 00000005413.75'. I want to convert this into packed decimal. Is there someway to do it using SORT? I could find ways to convert PD to edited numeric and not the other way round. And my input format is not ZD.
Could someone help me out please?

Thanks,
Sathya
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Tue May 08, 2007 11:25 pm
Reply with quote

You can use use DFSORT's UFF or SFF formats to handle values like that and TO=PD to convert to packed decimal. For example, if your character value was in positions 1-15, you could use these DFSORT control statements:

Code:

   OPTION COPY                           
   INREC BUILD=(1,15,UFF,TO=PD,LENGTH=8) 


For more information on DFSORT's UFF and SFF formats, see:

Use [URL] BBCode for External Links
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts JCL sort to compare dates in two file... DFSORT/ICETOOL 2
No new posts Is this possible via sort (in one pass)? SYNCSORT 4
No new posts GDG generation name to GDG Base name ... DFSORT/ICETOOL 3
No new posts SORT on detail record, then repeat he... DFSORT/ICETOOL 3
No new posts FB to .CSV conversion using sort DFSORT/ICETOOL 7
Search our Forums:

Back to Top