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

No.of record satisfying the search criteria...


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

New User


Joined: 23 Jul 2008
Posts: 29
Location: Little Rock - Arkansas

PostPosted: Mon May 18, 2009 9:08 pm
Reply with quote

Hi,

I have got a requirement where in based on key field i need to search in the file which has got millions of records get it n copy it and also i want to know at what particular row the record is present in the file.

Thx,
Satish
Back to top
View user's profile Send private message
Skolusu

Senior Member


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

PostPosted: Mon May 18, 2009 9:33 pm
Reply with quote

Assuming your input is FB and 80 byte LRECL, the following DFSORT JCL will give you the desired results. The row number is present in bytes 81 thru 88

Code:

//STEP0100 EXEC PGM=SORT               
//SYSOUT   DD SYSOUT=*                 
//SORTIN   DD *                       
         ABCD                         
         1111                         
         BLAH                         
         ABCD                         
//SORTOUT  DD SYSOUT=*                 
//SYSIN    DD *                       
  SORT FIELDS=COPY                     
  INREC OVERLAY=(81:SEQNUM,8,ZD)       
  OUTFIL INCLUDE=(10,4,CH,EQ,C'ABCD') 
/*
Back to top
View user's profile Send private message
satish kanamarlapudi

New User


Joined: 23 Jul 2008
Posts: 29
Location: Little Rock - Arkansas

PostPosted: Mon May 18, 2009 9:54 pm
Reply with quote

thx a lot sri... n sorry i didnot mention the bytes n length of the files...
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 How to split large record length file... DFSORT/ICETOOL 10
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Search two or more word with FILEAID Compuware & Other Tools 15
No new posts Sortjoin and Search for a String and ... DFSORT/ICETOOL 1
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
Search our Forums:

Back to Top