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
 

 

TO SKIP specific number of records from the i/p file

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

New User


Joined: 23 Sep 2008
Posts: 1
Location: USA

PostPosted: Thu Oct 23, 2008 10:37 pm    Post subject: TO SKIP specific number of records from the i/p file
Reply with quote

Hi,

I heard that SKIPREC=z will skip first z records from the input files.
I want a single sort card to skip records 2, 100, 500 and 550 from the input file. Can any body help me out in this regard?
Back to top
View user's profile Send private message

Skolusu

Senior Member


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

PostPosted: Thu Oct 23, 2008 11:35 pm    Post subject:
Reply with quote

dckreddy,

You can do this quite easily using the new SUBSET operator of DFSORT's ICETOOL available with z/OS DFSORT V1R5 PTF UK90013 (July, 2008) like this:
Code:

//STEP0100 EXEC PGM=ICETOOL                                           
//TOOLMSG  DD SYSOUT=*                                               
//DFSMSG   DD SYSOUT=*                                               
//IN       DD DSN=...  input file
//OUT      DD DSN=...  output file                                               
//TOOLIN   DD *                                                       
SUBSET FROM(IN) TO(OUT) REMOVE INPUT RRN(2) RRN(100) RRN(500) RRN(550)
/*   


For complete details on the new SUBSET function and the other new functions available with PTF UK90013, see:

www.ibm.com/systems/support/storage/software/sort/mvs/ugpf/
Back to top
View user's profile Send private message
suma_infy

New User


Joined: 03 Oct 2008
Posts: 25
Location: chennai

PostPosted: Fri Oct 24, 2008 10:22 am    Post subject:
Reply with quote

Kolusu,

I'm not provided with the above said version of DFSORT'S ICETOOL.

This is what the msg displayed in the spool.

SUBSET FROM(INDD1) TO(OUTDD1) REMOVE INPUT RRN(2) RRN(40)
£
INVALID OPERATOR
OPERATION RETURN CODE: 12

Is there anyother way to skip selective records from i/p file?
Thanks in advance.

Thanks & Regards,
Suma
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Fri Oct 24, 2008 11:09 am    Post subject:
Reply with quote

Hi,

you can try this
Code:
//STEP1    EXEC PGM=SORT                                               
//SYSOUT   DD SYSOUT=*                                                 
//SORTIN   DD DSN=INPUT-FILE LRECL 80                                   
//SORTOUT  DD SYSOUT=*                                                 
//SYSIN    DD *                                                         
  SORT FIELDS=COPY                                                     
  INREC OVERLAY=(81:SEQNUM,8,ZD)                                       
  OUTFIL OMIT=(81,8,ZD,EQ,+2,OR,                                       
                81,8,ZD,EQ,+40),                                       
      BUILD=(1,80)                                                     
/*                                                                     



Gerry
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: Fri Oct 24, 2008 9:12 pm    Post subject:
Reply with quote

Suma,

Quote:
I'm not provided with the above said version of DFSORT'S ICETOOL.


If you're using z/OS DFSORT V1R5, then you just need a PTF, not a new version. Ask your System Programmer to install z/OS DFSORT V1R5 PTF UK90013 (July, 2008) - it's free.

Note that Gerry's solution assumes your input file has RECFM=FB and LRECL=80 and would have to be changed for other attributes. The SUBSET solution can be used for any attributes without change.
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 Converting Variable block file to Fix... bhavana yalavarthi DFSORT/ICETOOL 10 Tue May 16, 2017 2:20 pm
No new posts Check if any Detail records and extra... V S Amarendra Reddy SYNCSORT 19 Mon May 08, 2017 8:54 pm
No new posts Getting error while opening a variabl... apandey1 COBOL Programming 5 Fri May 05, 2017 12:22 pm
No new posts SMTP the current generation number of... Jyothi Kulunde JCL & VSAM 4 Thu May 04, 2017 4:08 pm
No new posts Issue with NDM process to transmit ES... chetanambi All Other Mainframe Topics 6 Wed May 03, 2017 10:52 am


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