IFTHEN - syntax error



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

IFTHEN - syntax error

Postby knobi » Tue Oct 05, 2021 3:45 am

Good afternoon !
I'm having issues with the sort below, where :
- The 1st IFTHEN add a column that applies to all entries.
- The 2nd IFTHEN add a second column that applies to all entries (except the first line).
- The 3rd IFTHEN would add a third column which would apply to several groups of records. but the job fails on this statement with syntax error.

Could you please help me to understand how to add the 3rd IFTHEN statement ?

works fine :

//CTL1CNTL DD *  
 INREC IFTHEN=(WHEN=INIT,                
               OVERLAY=(90:SEQNUM,8,ZD)),          

       IFTHEN=(WHEN=GROUP,BEGIN=(23,03,SS,EQ,C'ID='),
               PUSH=(99:26,04))
 


fails with syntax error :

//CTL1CNTL DD *
INREC IFTHEN=(WHEN=INIT,
              OVERLAY=(90:SEQNUM,8,ZD)),

      IFTHEN=(WHEN=GROUP,BEGIN=(23,03,SS,EQ,C'ID='),              
              PUSH=(99:26,04)),          

      IFTHEN=(WHEN=GROUP,BEGIN=(01,20,SS,EQ,C'ABCABC ABC ABC21'),                
              END=(03,15,SS,EQ,C'ABCAAW-CASC'),                
              PUSH=(105:C'AEDX AXC'))
 
knobi
 
Posts: 9
Joined: Thu Aug 13, 2009 9:36 am
Has thanked: 0 time
Been thanked: 0 time

Re: IFTHEN - syntax error

Postby sergeyken » Tue Oct 05, 2021 10:37 pm

What is the error message?
What does it say?
What is the error position marked with '*' in the listing?
What is the whole JCL, and all control statements used by your ICETOOL step?

If you really need help, this is YOUR RESPONSIBILITY to provide as much useful info as possible.
We all are not very interested in pulling the information from you.
Javas and Pythons come and go, but JCL and SORT stay forever.
User avatar
sergeyken
 
Posts: 409
Joined: Wed Jul 24, 2019 10:12 pm
Has thanked: 6 times
Been thanked: 40 times

Re: IFTHEN - syntax error

Postby knobi » Sat Oct 09, 2021 12:49 am

I just found and fix the syntax on the error message mentioned above.
thanks
knobi
 
Posts: 9
Joined: Thu Aug 13, 2009 9:36 am
Has thanked: 0 time
Been thanked: 0 time

Re: IFTHEN - syntax error

Postby Terry Heinze » Sat Oct 09, 2021 7:51 am

knobi, it would be nice if you would post your solution for the benefit of others.
.... Terry
Terry Heinze
 
Posts: 239
Joined: Wed Dec 04, 2013 11:08 pm
Location: Richfield, MN, USA
Has thanked: 12 times
Been thanked: 11 times


Return to DFSORT/ICETOOL/ICEGENER

 


  • Related topics
    Replies
    Views
    Last post