Can I create a JCL to submit a REXX program



IBM's Command List programming language & Restructured Extended Executor

Can I create a JCL to submit a REXX program

Postby tander » Sat Nov 08, 2008 2:31 am

Hi There,

Question: JCL - REXX - JCL?

Can I create a JCL to submit a REXX program, that submits more JCL?

The code below doesn't give errors...but the sort-JCL, submitted by REXX, does not create an output file. (<OUT_FILE_NAME>)

What should I try to get <OUT_FILE_NAME> to create?

Thanks

-Tom

JCL:

//<MY_JOB_ID> JOB (TX,AUD),'01-3039',
// CLASS=F,
// PRTY=06,
// MSGCLASS=Z
//*
//STEP1 EXEC PGM=IEFBR14,DYNAMNBR=20
//SYSPROC DD DSN=<MY_LIBRARY>.CLIST,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
TSTREX15
/*

REXX (TSTREX15):

/* rexx */
QUEUE "//<MY_JOB_ID> JOB (TX,AUD),'01-3039 ', "
QUEUE "// CLASS=F,MSGCLASS=Z,PRTY=06 "
QUEUE "// JCLLIB ORDER=(@ZMF.AUD.TESTPROC) "
QUEUE "//STEP2 EXEC PGM=SORT "
QUEUE "//SORTMSGS DD SYSOUT=* "
QUEUE "//SYSOUT DD SYSOUT=* "
QUEUE "//SORTIN DD DSN=<IN_FILE_NAME>, "
QUEUE "// DISP=OLD "
QUEUE "//SORTOUT DD DSN=<OUT_FILE_NAME>, "
QUEUE "// DISP=(NEW,CATLG,DELETE), "
QUEUE "// UNIT=SYSWK, "
QUEUE "// SPACE=(CYL,(20,5),RLSE) "
QUEUE "//SORTWK01 DD UNIT=TSTDA,SPACE=(CYL,(15,5),RLSE) "
QUEUE "//SORTWK02 DD UNIT=TSTDA,SPACE=(CYL,(15,5),RLSE) "
QUEUE "//SORTWK03 DD UNIT=TSTDA,SPACE=(CYL,(15,5),RLSE) "
QUEUE "//SORTWK04 DD UNIT=TSTDA,SPACE=(CYL,(15,5),RLSE) "
QUEUE "//SYSIN DD * "
QUEUE " SORT FIELDS=(1,2,CH,A) "
QUEUE "/*"
QUEUE "$$"
"SUBMIT * END($$)"


PS -

A personal-scheduler-ready-jcl, that will place a date into the filename, depending on the month, is the goal. I want to use REXX to generate the date. Advice on ibmmainframes, for date-in-filename programs has been a BIG help to me, but I've hit a wall with this jcl - rexx - jcl.
tander
 

Re: jcl - rexx - jcl

Postby dick scherrer » Sat Nov 08, 2008 2:47 am

Hello Tom and welcome to the forum,

Your first jcl executes IEFBR14, so your rexx can never be executed. . . All thet br14 does is go to end of job - it never "sees" your input.
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: jcl - rexx - jcl

Postby tander » Sat Nov 08, 2008 3:10 am

Hey Thanks !!

Switched IEFBR14 to IKJEFT1A - now it works.

Thanks Again !! - Tom
tander
 

Re: jcl - rexx - jcl

Postby dick scherrer » Sat Nov 08, 2008 3:12 am

You're welcome - good luck :)

d
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 CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post