MVSFORUMS.com A Community of and for MVS Professionals
View previous topic :: View next topic
Author
Message
Murthy Beginner Joined: 25 Jan 2006 Posts: 4 Topics: 3
Posted: Thu Feb 02, 2006 4:05 am Post subject: Need Help In Rexx
Inserting Jobcard in any JCL thru RExx .
Back to top
ofer71 Intermediate Joined: 12 Feb 2003 Posts: 358 Topics: 4 Location: Israel
Posted: Thu Feb 02, 2006 4:24 am Post subject:
You should write an Edit-Macro. Edit-macro might be written in REXX (and in other languages, too).
Here is my JOBCARD macro:
Code:
/*--------------------------- REXX -----------------------------------
* PROGRAM : JOBCARD
* PURPOSE : GENERATE THE JOB CARD.
* PARAMETERS: JOB NAME (OPTIONAL).
* AUTHOR : OFERF
* DATE : 20 Nov 2002, 12:43:08
*------------------------------------------------------------------*/
ADDRESS "ISREDIT" "MACRO (ARG1) PROCESS"
SYSUID = '&SYSUID'
IF ARG1 = " " THEN ARG1 = USERID()||'-JOB'
CALL REXXLOG 'JOBC'
J01 = "//"USERID()"A JOB (23610,0,0668),'"||ARG1||"',MSGCLASS=X,"
J02 = "// MSGLEVEL=(1,1),CLASS=S,NOTIFY="||SYSUID
J03 = "//*" ||COPIES('-',67)||"*"
ADDRESS ISREDIT "LINE_AFTER 00 = (J01)"
ADDRESS ISREDIT "LINE_AFTER 01 = (J02)"
ADDRESS ISREDIT "LINE_AFTER 02 = (J03)"
ADDRESS ISREDIT "CURSOR = 1 0"
ADDRESS ISREDIT "RESET"
EXIT
O.
________
gm foods Last edited by ofer71 on Sat Feb 05, 2011 11:30 am; edited 1 time in total
Back to top
Mervyn Moderator Joined: 02 Dec 2002 Posts: 415 Topics: 6 Location: Hove, England
Posted: Thu Feb 02, 2006 4:38 am Post subject:
Just for the sake of variety:
Code:
/* rexx edit macro to insert job cards */
address isredit
"MACRO"
address ispexec "VGET (ZUSER ZACCTNUM)"
job1 = "//"zuser"A JOB ("zacctnum"),'"zuser"',"
job2 = "// CLASS=D,MSGCLASS=X,NOTIFY="zuser
"LINE_AFTER 0 = '//*'"
"LINE_AFTER 0 = '/*JOBPARM L=99,ROOM=QH'"
"LINE_AFTER 0 = '//*'"
"LINE_AFTER 0 = (JOB2)"
"LINE_AFTER 0 = (JOB1)"
_________________ The day you stop learning the dinosaur becomes extinct
Back to top
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum