Monday, September 26, 2011

REXX : Sample REXX program to submit a job


Below sample REXX program submits a job when it is executed.

USER = USERID()
QUEUE "//"USER"A JOB (11212),'TEST',CLASS=G,MSGCLASS=X,"
QUEUE "// NOTIFY="USER",PRTY=14"
QUEUE "//STEP01 EXEC PGM=IEFBR14        "
QUEUE "// "
QUEUE "$$ "
O = OUTTRAP("OUTPUT.",,"CONCAT")
"SUBMIT * END($$)" /* SUBMIT JCL */
O = OUTTRAP(OFF)
/* OUTPUT LINE SAYING SUBMITTED AND JOB#### */
SAY OUTPUT.2

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.