Overview of ProcedureCreate an MSG rule to strip out the report id and gen values that are needed and to call the program that will create and recall the report. For example, write a REXX EXEC to create and submit a SARBCH LOAD job for CA VIEW. The REXX exec will accept the report id and gen values as input.
NOTE: This is just a sample. Please configure for your environment. You will need to make sure that the REXX is in your SYSEXEC for your servers and that your OSFGETJOBID is set to YES.
- CA DRAS generates a message like this when a CA Output Management Web Viewer user selects an archived report:
CAHATPR02 Report "99999" Gen=9999 Seq=1 User USERID recall request
CAHATPR02 Report "rid" Gen=gen Seq=seq User user DB db_hlq recall request - NOTE: This message should be set up in DRAS with a SET WTO SAMPLE (MSG rule
- This rule is executed when CAHATPR02 is detected in the DRAS log. It parses the message, extracts the two needed values and calls the REXX exec to build and submit the recall job.
Sample MSG Rule in DRASNOTE: This message should be set up in DRAS with a SET WTOSAMPLE (MSG rule. This rule is executed when CAHATPR02 is detected in the DRAS log. It parses the message, extracts the two needed values and calls the REXX exec to build and submit the recall job.
)msg CAHATPR02
)proc
MG=msg.text /* assigns text of message to a value of MG */
id# = word(MG,3) /* 3rd word in message assigned to id# */
id# = STRIP(id#,,'"') /* removes the quotes from id# (word3) */
gen# = word(MG,4) /* 4th word in message assigned to gen# */
ADDRESS OSF
"OI SUBMTJOB" id# gen# /* Execute SUBMTJOB REXX which submits job with values */
return
Sample SUBMTJOB REXX EXEC to BUILD and SUBMIT the recall JCL
Parse arg id# gen# /* value of word 3 and word 4 */ line.1 = "//J12345 JOB ,'SAR REPORT RETRIEVAL',CLASS=N,"
line.2 = "// MSGCLASS=J,MSGLEVEL=(1,1)"
line.3 = "//STARTUP1 EXEC UCC11RMS"
line.4 = "//STEP1 EXEC PGM=SARBCH,PARM='P06.D63200A.SAR'"
line.5 = "//STEPLIB DD DSN=SYS3.SAR.LOADLIB,DISP=SHR"
line.6 = "//SYSPRINT DD SYSOUT=*"
line.7 = "//REPORT DD SYSOUT=(A,,C611)"
line.8 = "//SYSIN DD *"
line.9 = "/LOAD ID="id# gen# /* inserts values of word 3 and word 4 */
zz = OPSUBMIT(line.)
If rc <> 0 then
Do while queued() <> 0
pull msg
say msg
End