Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to Prefix Zeroes?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
manyamtej

New User


Joined: 14 Sep 2007
Posts: 3
Location: Bangalore

PostPosted: Tue Jun 02, 2009 11:57 am    Post subject: How to Prefix Zeroes?
Reply with quote

I have a requirement to format the input of 1 to 6 digits to standard 6 digit number by prefixing zeros. Eg: input: 123 1234 12 Out put: 000123 001234 000012 Can some help me with sort card.
Back to top
View user's profile Send private message

Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Tue Jun 02, 2009 8:58 pm    Post subject:
Reply with quote

manyamtej,
Code:

//STEP0100 EXEC PGM=SORT                 
//SYSOUT   DD SYSOUT=*                   
//SORTIN   DD *                         
1                                       
12                                       
123                                     
1234                                     
12345                                   
123456                                   
//SORTOUT  DD SYSOUT=*                   
//SYSIN    DD *                         
  SORT FIELDS=COPY                       
  INREC OVERLAY=(1:1,6,UFF,M11,LENGTH=6)
/*


will produce
Code:

000001
000012
000123
001234
012345
123456
Back to top
View user's profile Send private message
rafael2009

New User


Joined: 21 May 2009
Posts: 18
Location: Mumbai

PostPosted: Thu Jun 04, 2009 5:45 pm    Post subject:
Reply with quote

please could you tell me the meaning of UFF and M11
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Thu Jun 04, 2009 6:13 pm    Post subject:
Reply with quote

Quote:
please could you tell me the meaning of UFF and M11



Have you tried clicking link given in Kolusu's signature?
i.e www.ibm.com/storage/dfsort/

It will give answer of your both queries
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


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

PostPosted: Thu Jun 04, 2009 9:14 pm    Post subject:
Reply with quote

UFF is unsigned free format. M11 is an edit mask with leading zeros.

If you're not familiar with DFSORT and DFSORT's ICETOOL, I'd suggest reading through "z/OS DFSORT: Getting Started". It's an excellent tutorial, with lots of examples, that will show you how to use DFSORT, DFSORT's ICETOOL and DFSORT Symbols. You can access it online, along with all of the other DFSORT books, from:

www.ibm.com/servers/storage/support/software/sort/mvs/srtmpub.html
Back to top
View user's profile Send private message
rafael2009

New User


Joined: 21 May 2009
Posts: 18
Location: Mumbai

PostPosted: Fri Jun 05, 2009 1:03 pm    Post subject:
Reply with quote

Thank you Frank...
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Format record to remove Leading zeroes Learncoholic DFSORT/ICETOOL 14 Wed Apr 05, 2017 2:43 pm
No new posts No TSO prefix doesn't get the input boyti ko CLIST & REXX 4 Thu Apr 28, 2016 3:31 pm
No new posts Add Trailing Zeroes depending upon th... Rohit Umarjikar DFSORT/ICETOOL 3 Fri Oct 23, 2015 1:47 am
No new posts To insert zeroes in a PIPE delimited ... dharmaraok DFSORT/ICETOOL 3 Mon Mar 16, 2015 3:05 pm
No new posts CSV file , to display numeric data w... Deepthy Jose P JCL & VSAM 10 Fri Nov 21, 2014 12:50 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us