Include Member



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

Include Member

Postby lakshmanan » Thu Jul 24, 2008 9:56 pm

Hi,
I have a common Include member, which contains few JCL steps, used in 8 jobs. Every job passes a 2 char value as a symbolic parameter to the include member to be used in jcl steps. For Eg. SET CC1=GB is coded in a job. I'm trying to skip a step only in that particular job where CC1 is set a GB. I cannot go and change the include member as it is wil impact other jobs too.

I tried with an IF statement like below thinking that it wil skip the step only for GB and will work for other values.

//IFSTEP04 IF (&CC1 NOT = GB) THEN
//...
//...
//ENDIF04 ENDIF

I'm getting the error as "NON NUMERIC ARGUMENT TO IF KEYWORD".
Can IF statement be used for other than return code checking?
Is there any other way to resolve this.

thanks.
lakshmanan
 
Posts: 9
Joined: Tue Mar 25, 2008 2:26 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Include Member

Postby dick scherrer » Thu Jul 24, 2008 10:07 pm

Hello,

Please post your jcl.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times

Re: Include Member

Postby lakshmanan » Thu Jul 24, 2008 10:34 pm

Hi,

This is my JCL.
//         SET JOBCHK=APGB912
//         SET CC1=GB
//         SET CC=GB.
//         SET IRLMID=IRL2
//         SET DB2ID=DSNT
//         SET I18NLIB=WM.SP.PARMLIB
//         SET I18NMBR=DUMMY
//*
//JOBLIB   DD DSN=WM.TESTLINK,DISP=SHR
//         DD DSN=WM.SP.LINKLIB,DISP=SHR
//*
//LIBSRCH  JCLLIB ORDER=(WM.SP.APPLIC.PROCLIB,
//         WM.SP.DBA.PROCLIB,
//         WM.PROCLIB,
//         N01.P5.FIN.JOB.RESOURCE,
//         LMURUGE.CA7.INCLUDE)
//*
//         INCLUDE MEMBER=(VNGB912)
//*
//CA7DMY   EXEC PGM=IEFBR14
//STEPS    INCLUDE MEMBER=(VNSP912I)
//


The include member VNSP912I has the JCL steps as given below. It is in the PDS LMURUGE.CA7.INCLUDE.
//STEP03   EXEC FILEAID
//DD01     DD DSN=LMURUGE.GB.FIN.FTP.ASDA.VENDOR.MASTER,
//             DISP=SHR
//EXTRACT  DD DSN=T01.&CC.FIN.ASDA.VENDOR.EXTRACT,
//             DISP=(,CATLG,DELETE),
//             LRECL=203,RECFM=FB,
//             SPACE=&SIZE003,
//             DSORG=PS,AVGREC=K
//SYSIN    DD DSN=LMURUGE.FIN.SYSTEM.PARMLIB(VN91203),DISP=SHR
//*---------------------------------------------------------------------
//IFSTEP04 IF (&CC1 = AR) THEN  -----> This statement gives error
//STEP04   EXEC SORT
//SORTIN   DD DSN=T01.&CC.FIN.ASDA.VENDOR.EXTRACT,
//             DISP=SHR
//SORTOUT  DD DSN=T01.&CC.FIN.ASDA.VENDOR.EXTRACT.SORTSUM,
//             DISP=(,CATLG,DELETE),
//             LRECL=203,RECFM=FB,
//             SPACE=&SIZE004,
//             DSORG=PS,AVGREC=K
//SYSIN    DD DSN=LMURUGE.FIN.SYSTEM.PARMLIB(VN91204),DISP=SHR
//ENDIF04  ENDIF



Thanks.
lakshmanan
 
Posts: 9
Joined: Tue Mar 25, 2008 2:26 pm
Has thanked: 0 time
Been thanked: 0 time

Re: Include Member

Postby dick scherrer » Thu Jul 24, 2008 11:29 pm

Hello,

I cannot go and change the include member as it is wil impact other jobs too.
It appears that you will have to change the member - as it is it will not execute. . .

When you change the member, you could add a step that takes &cc1 as a parm and sets a return code according to what value was specified. Then your jcl could test the recurn code and all should be ok.
Hope this helps,
d.sch.
User avatar
dick scherrer
Global moderator
 
Posts: 6268
Joined: Sat Jun 09, 2007 8:58 am
Has thanked: 3 times
Been thanked: 93 times


Return to JCL

 


  • Related topics
    Replies
    Views
    Last post