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

Help needed on SORT to exclude records


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

New User


Joined: 26 Apr 2005
Posts: 87
Location: Hyderabad

PostPosted: Mon Nov 15, 2010 5:22 pm
Reply with quote

Hi Friends,

I want to omit the records having zeroes starting from 236 bytes to next 720 bytes.

But all are 72 times, 10 bytes packed decimal fields.

Can you please help me here?

Regards
Tanden
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Mon Nov 15, 2010 5:41 pm
Reply with quote

Please DO NOT tag your topic onto an existing one. Especially one that has been dormant for some time.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Mon Nov 15, 2010 10:11 pm
Reply with quote

Tanden,

What is the RECFM and LRECL of your input file?
Back to top
View user's profile Send private message
notonly4u

New User


Joined: 26 Apr 2005
Posts: 87
Location: Hyderabad

PostPosted: Tue Nov 16, 2010 2:54 pm
Reply with quote

Dear Frank,

My dataset is with LRECL=2155, FB.
Thanks for your reply.

Regards
Tanden
Back to top
View user's profile Send private message
Skolusu

Senior Member


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

PostPosted: Tue Nov 16, 2010 11:13 pm
Reply with quote

notonly4u,

Use the following DFSORT JCL

Code:

//STEP0100 EXEC PGM=SORT               
//SYSOUT   DD SYSOUT=*                 
//SORTIN   DD DSN=Your Input FB 2155 byte file,DISP=SHR
//SORTOUT  DD SYSOUT=*
  SORT FIELDS=COPY                                   
  OMIT COND=(236,10,PD,EQ,0,AND,246,10,PD,EQ,0,AND, 
             256,10,PD,EQ,0,AND,266,10,PD,EQ,0,AND, 
             276,10,PD,EQ,0,AND,286,10,PD,EQ,0,AND, 
             296,10,PD,EQ,0,AND,306,10,PD,EQ,0,AND, 
             316,10,PD,EQ,0,AND,326,10,PD,EQ,0,AND, 
             336,10,PD,EQ,0,AND,346,10,PD,EQ,0,AND, 
             356,10,PD,EQ,0,AND,366,10,PD,EQ,0,AND, 
             376,10,PD,EQ,0,AND,386,10,PD,EQ,0,AND, 
             396,10,PD,EQ,0,AND,406,10,PD,EQ,0,AND, 
             416,10,PD,EQ,0,AND,426,10,PD,EQ,0,AND, 
             436,10,PD,EQ,0,AND,446,10,PD,EQ,0,AND, 
             456,10,PD,EQ,0,AND,466,10,PD,EQ,0,AND, 
             476,10,PD,EQ,0,AND,486,10,PD,EQ,0,AND, 
             496,10,PD,EQ,0,AND,506,10,PD,EQ,0,AND, 
             516,10,PD,EQ,0,AND,526,10,PD,EQ,0,AND, 
             536,10,PD,EQ,0,AND,546,10,PD,EQ,0,AND, 
             556,10,PD,EQ,0,AND,566,10,PD,EQ,0,AND, 
             576,10,PD,EQ,0,AND,586,10,PD,EQ,0,AND, 
             596,10,PD,EQ,0,AND,606,10,PD,EQ,0,AND, 
             616,10,PD,EQ,0,AND,626,10,PD,EQ,0,AND, 
             636,10,PD,EQ,0,AND,646,10,PD,EQ,0,AND, 
             656,10,PD,EQ,0,AND,666,10,PD,EQ,0,AND, 
             676,10,PD,EQ,0,AND,686,10,PD,EQ,0,AND, 
             696,10,PD,EQ,0,AND,706,10,PD,EQ,0,AND, 
             716,10,PD,EQ,0,AND,726,10,PD,EQ,0,AND, 
             736,10,PD,EQ,0,AND,746,10,PD,EQ,0,AND, 
             756,10,PD,EQ,0,AND,766,10,PD,EQ,0,AND, 
             776,10,PD,EQ,0,AND,786,10,PD,EQ,0,AND, 
             796,10,PD,EQ,0,AND,806,10,PD,EQ,0,AND, 
             816,10,PD,EQ,0,AND,826,10,PD,EQ,0,AND, 
             836,10,PD,EQ,0,AND,846,10,PD,EQ,0,AND, 
             856,10,PD,EQ,0,AND,866,10,PD,EQ,0,AND, 
             876,10,PD,EQ,0,AND,886,10,PD,EQ,0,AND, 
             896,10,PD,EQ,0,AND,906,10,PD,EQ,0,AND, 
             916,10,PD,EQ,0,AND,926,10,PD,EQ,0,AND, 
             926,10,PD,EQ,0,AND,946,10,PD,EQ,0)     
//*
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Wed Nov 17, 2010 1:57 am
Reply with quote

FWIW, here's another way to do it with DFSORT. This is a little easier to set up, but probably not as efficient. Also, it can only handle a C sign for the PD 0 values whereas Kolusu's job can handle any sign.

Code:

  OPTION COPY                                   
  INREC OVERLAY=(2156:72X'0000000000000000000C')
  OUTFIL OMIT=(236,256,BI,EQ,2156,256,BI,AND,   
     492,256,BI,EQ,2412,256,BI,AND,             
     748,208,BI,EQ,2668,208,BI),                 
    BUILD=(1,2155)                               
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 Compare 2 files and retrive records f... DFSORT/ICETOOL 0
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
No new posts Need to set RC4 through JCL SORT DFSORT/ICETOOL 5
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Compare only first records of the fil... SYNCSORT 7
Search our Forums:

Back to Top