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
 
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 Compare yesterday's date to the one o... migusd SYNCSORT 7 Fri Sep 22, 2017 11:35 pm
No new posts Split 1 file into 10 output Files - S... Prasanth Kumar SYNCSORT 5 Sat Sep 16, 2017 12:02 am
No new posts BUILD OUTFIL based on condition other... balaji81_k DFSORT/ICETOOL 13 Fri Sep 08, 2017 11:06 pm
No new posts Skip file from delete pema_yozer All Other Mainframe Topics 3 Tue Aug 29, 2017 3:19 pm
No new posts Join records from 2 files with No Dup... Poha Eater DFSORT/ICETOOL 21 Sun Aug 27, 2017 10:35 pm

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