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 write sort condition for this Problem

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

New User


Joined: 01 Jun 2005
Posts: 14

PostPosted: Sat Jun 11, 2005 5:34 pm    Post subject: How to write sort condition for this Problem
Reply with quote

6. Suppose I want to compare the 8 ,9 th character with 11 and 12 th character in vsam file if it is matching I should sort how to write sort condition for that
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: Sat Jun 11, 2005 8:22 pm    Post subject:
Reply with quote

If the VSAM input records can be treated as F (fixed-length), you can use a DFSORT job like this:

Code:

//F EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=...  VSAM input file
//SORTOUT DD DSN=...   output file
//SYSIN DD *
   RECORD TYPE=F
   INCLUDE COND=(8,2,CH,EQ,11,2,CH)
   SORT FIELDS=(p,m,f,s)
/*


If the VSAM input records must be treated as V (variable-length), you can use a DFSORT job like this (you must add 4 to the starting positions to account for the RDW DFSORT uses to process the records as variable-length):

Code:

//V EXEC PGM=ICEMAN
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=...  VSAM input file
//SORTOUT DD DSN=...   output file
//SYSIN DD *
   RECORD TYPE=V
   INCLUDE COND=(12,2,CH,EQ,15,2,CH)
   SORT FIELDS=(p+4,m,f,s)
/*


For more information on processing VSAM files as F or V with DFSORT, see:

http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA10/1.8.3.4?SHELF=&DT=20050222160456&CASE=
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 Problem reading GTF trace output danik56 ABENDS & Debugging 7 Thu Mar 16, 2017 1:02 pm
No new posts Innovations in Your Mainframe Sort Arun Raj PC Guides & IT News 4 Wed Mar 15, 2017 10:38 pm
No new posts SORT VSAM file with each field one by... maxsubrat DFSORT/ICETOOL 6 Tue Mar 14, 2017 1:07 pm
No new posts SORT requirement sjiraga COBOL Programming 6 Thu Mar 09, 2017 9:11 pm
No new posts SORT to append Month and YEAR in MMYY... tisamf DFSORT/ICETOOL 1 Wed Mar 08, 2017 4:46 pm


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