Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
DFSORT/ICETOOL SORTING RECORDS IN DESIRED FORMAT

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

New User


Joined: 21 Jan 2009
Posts: 2
Location: hyd

PostPosted: Wed Jan 28, 2009 6:40 pm    Post subject: DFSORT/ICETOOL SORTING RECORDS IN DESIRED FORMAT
Reply with quote

Input:
Code:

A   B   C   D   E


for this input i want to get the output as bellow

Output:
Code:

A   B   C   D   E   
B   A   C   D   E
C   A   B   D   E
D   A   B   C   E
E   A   B   C   D


Is this Possible?
Back to top
View user's profile Send private message

cpuhawg

Active User


Joined: 14 Jun 2006
Posts: 331
Location: Jacksonville, FL

PostPosted: Wed Jan 28, 2009 6:54 pm    Post subject: Reply to: DFSORT/ICETOOL SORTING RECORDS IN DESIRED FORMAT
Reply with quote

This should work for you:


Code:

//ICETOOL  EXEC PGM=ICETOOL                           
//TOOLMSG  DD  SYSOUT=*                               
//DFSMSG   DD  SYSOUT=*                               
//TOOLIN   DD  *                                     
COPY FROM(INPUT) TO(OUTFILE) USING(CTL1)             
//SYSOUT   DD  SYSOUT=*                               
//SYSUDUMP DD  SYSOUT=*                               
//INPUT    DD  *                                     
A B C D E                                             
//OUTFILE  DD  DSN=...  output file (FB/80)                               
//CTL1CNTL DD  *                                     
 OUTFIL FNAMES=OUTFILE,                               
   BUILD=(1:1,2,3:3,2,5:5,2,7:7,2,9:9,2,80:X,/,       
          1:3,2,3:1,2,5:5,2,7:7,2,9:9,2,/,           
          1:5,2,3:1,2,5:3,2,7:7,2,9:9,2,/,           
          1:7,2,3:1,2,5:3,2,7:5,2,9:9,2,/,           
          1:9,2,3:1,2,5:3,2,7:5,2,9:7,2)         
/*
Back to top
View user's profile Send private message
Skolusu

Senior Member


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

PostPosted: Wed Jan 28, 2009 11:59 pm    Post subject:
Reply with quote

Sukku_mar3,

The following DFSORT JCL will give you the desired results

Code:

//STEP0100 EXEC PGM=ICEMAN             
//SYSOUT   DD SYSOUT=*                 
//SORTIN   DD *                       
A   B   C   D   E                     
//SORTOUT  DD SYSOUT=*                 
//SYSIN    DD *                       
  SORT FIELDS=COPY                     
  OUTFIL BUILD=(01,80,/,               
                05,04,01,04,09,72,/,   
                09,04,01,08,13,68,/,   
                13,04,01,12,17,64,/,   
                17,04,01,16,21,60)     
/*
Back to top
View user's profile Send private message
sukku_mar3

New User


Joined: 21 Jan 2009
Posts: 2
Location: hyd

PostPosted: Thu Jan 29, 2009 10:54 am    Post subject: DFSORT/ICETOOL SORTING RECORDS IN DESIRED FORMAT
Reply with quote

thank u for ur reply,
But actually my input is
A B C D..........Y Z.

Just to know how to proceed only I have given the input as
A B C D E

If I proceed in your way,It will be lengthy.
We cannot do every time for a lengthy record like this kind of overlapping right.
I want to know whether is there any otherway (like any keyfiends that we can consider) to shorten this process.
Can you help me out in this.
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 Jan 29, 2009 9:42 pm    Post subject:
Reply with quote

Quote:
I want to know whether is there any otherway (like any keyfiends that we can consider) to shorten this process.


What process? What keyfields? You haven't explained anything about what you're trying to do. Maybe if you did, we could come up with a more relevant solution.

Your Subject title mentions sorting, but you haven't explained where "sorting" fits into this.

Do you only have one input record or do you have multiple input records?

Give a better explanation of what you're trying to do with a better example.
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 Merging 2 records at multiple rows wi... Bijesh DFSORT/ICETOOL 1 Wed Dec 06, 2017 1:50 am
No new posts Formatting using DFsort Guru Nandu DFSORT/ICETOOL 5 Thu Nov 30, 2017 7:33 am
No new posts Compare VSAM files using DFSORT pshongal DFSORT/ICETOOL 5 Thu Nov 23, 2017 10:24 am
No new posts ICETOOL - RESIZE DYNAMICALLY kranthikumarb DFSORT/ICETOOL 0 Tue Nov 21, 2017 5:30 pm
No new posts Compare and COPY using DFSORT pshongal DFSORT/ICETOOL 3 Fri Nov 17, 2017 9:49 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us