String Search



IBM's flagship sort product DFSORT for sorting, merging, copying, data manipulation and reporting. Includes ICETOOL and ICEGENER

String Search

Postby Vineet » Tue Feb 05, 2013 9:36 pm

Hi All,

I am having a seqential file having LRECL=80 & RECFM=FB. My requirement is, If starting from position 1, Length = 3, I am having Char. "EOF" I need to set the return code = 4. How can I do this using SORT.

Thanks.
Vineet
 
Posts: 86
Joined: Tue Jun 19, 2007 11:38 am
Has thanked: 0 time
Been thanked: 0 time

Re: String Search

Postby steve-myers » Tue Feb 05, 2013 9:56 pm

Any record, first record, last record????
steve-myers
Global moderator
 
Posts: 2105
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 243 times

Re: String Search

Postby Vineet » Tue Feb 05, 2013 9:59 pm

Well we can san Only 1 Record in the File & Having 3 Char starting from Position 1 & Length = 3 as "EOF".

Rgd's
Vineet
 
Posts: 86
Joined: Tue Jun 19, 2007 11:38 am
Has thanked: 0 time
Been thanked: 0 time

Re: String Search

Postby enrico-sorichetti » Tue Feb 05, 2013 10:46 pm

search the manuals and the forums for the use of the NULLOUT clause
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2994
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 164 times

Re: String Search

Postby skolusu » Tue Feb 05, 2013 10:50 pm

Vineet,

It would be nice if you can post a feed back for the prior solutions you got. You ask a question receive a solution and then disappear until you have a new question. How hard is it to just provide feedback if the solution worked or not?

Any way here is the solution you looking for. Use the following DFSORT/ICETOOL JCL which will give you the desired results
//STEP0100 EXEC PGM=ICETOOL               
//TOOLMSG  DD SYSOUT=*                   
//DFSMSG   DD SYSOUT=*                   
//IN       DD *                           
BLAH                                     
BLUE                                     
EOF                                       
RED                                       
GREEN     
EOF                               
//OUT      DD SYSOUT=*                   
//TOOLIN   DD *                           
  COUNT FROM(IN) HIGHER(0) RC4 USING(CTL1)
//CTL1CNTL DD *                           
  INCLUDE COND=(1,3,CH,EQ,C'EOF')   
//*
skolusu
 
Posts: 586
Joined: Wed Apr 02, 2008 10:38 pm
Has thanked: 0 time
Been thanked: 39 times

Re: String Search

Postby Vineet » Tue Feb 05, 2013 11:29 pm

Thanks SKOLUSU, it worked me.

Rgd's
Vineet
 
Posts: 86
Joined: Tue Jun 19, 2007 11:38 am
Has thanked: 0 time
Been thanked: 0 time


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post