Page 1 of 1

Syncsort IFTHEN(WHEN=GROUP)

PostPosted: Wed Nov 11, 2009 1:16 pm
by bhuvan!2b
Hi all,
I am working on a small code to list the limit for a given group of GDG Bases. This is the code I have written. But there seems to be some syntax error in the GROUP parameter. Could any 1 help me on this....

OPTION COPY
INCLUDE COND=(1,8,CH,EQ,C'GDG BASE',OR,8,5,CH,EQ,C'LIMIT')
INREC IFTHEN=(WHEN=GROUP,RECORDS=2,BEGIN=(1,8,CH,EQ,C'GDG BASE'),
PUSH=(35:17,36))
OUTFIL INCLUDE=(8,5,CH,EQ,C'LIMIT'),
BUILD=(35,36,C'HAS A LIMIT OF: ',
17,15,ZD,M11,LENGTH=3)

Re: DFSORT IFTHEN(WHEN=GROUP)

PostPosted: Wed Nov 11, 2009 11:08 pm
by Frank Yaeger
When I run your DFSORT control statements, I do not get any syntax errors:

  OPTION COPY                                                       
  INCLUDE COND=(1,8,CH,EQ,C'GDG BASE',OR,8,5,CH,EQ,C'LIMIT')       
  INREC IFTHEN=(WHEN=GROUP,RECORDS=2,BEGIN=(1,8,CH,EQ,C'GDG BASE'),
   PUSH=(35:17,36))                                                 
  OUTFIL INCLUDE=(8,5,CH,EQ,C'LIMIT'),                             
   BUILD=(35,36,C'HAS A LIMIT OF: ',                               
   17,15,ZD,M11,LENGTH=3)                                           


Make sure position 1 is blank in every line. If so, then show the DFSORT messages you received.

Re: DFSORT IFTHEN(WHEN=GROUP)

PostPosted: Thu Nov 12, 2009 3:32 pm
by bhuvan!2b
Hi...
thanks for ur rply.... i have started the sort commands in 3 rd column of my jcl.. and following is the err msg..
I guess when=group is command is not recognised in syncsort. is it so.. but it recognises when=init.. :x

 SYSIN :
  OPTION COPY
  INCLUDE COND=(1,8,CH,EQ,C'GDG BASE',OR,8,5,CH,EQ,C'LIMIT')
  INREC IFTHEN=(WHEN=GROUP,RECORDS=2,BEGIN=(1,8,CH,EQ,C'GDG BASE'),
                     *
                        PUSH=(35:17,36))
     OUTFIL INCLUDE=(8,5,CH,EQ,C'LIMIT'),
            BUILD=(35,36,C'HAS A LIMIT OF: ',
                        17,15,ZD,M11,LENGTH=3)
 WER268A  INREC STATEMENT   : SYNTAX ERROR
 WER211B  SYNCSMF  CALLED BY SYNCSORT; RC=0000
 WER449I  SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE

Re: Syncsort IFTHEN(WHEN=GROUP)

PostPosted: Fri Nov 13, 2009 3:13 am
by dick scherrer
Hello,

Which release of Syncsort is being used?

WHEN=GROUP works in the current release of Syncsort.