REXX AND ISPF RETURN CODE PROBLEM



IBM's Command List programming language & Restructured Extended Executor

REXX AND ISPF RETURN CODE PROBLEM

Postby good123 » Mon Apr 25, 2011 12:10 pm

Dear all:
i am try to run a rexx and using ISPF LMMFIND service to get meber's some infomation,when mem not
found,set rc to 16 and exit rexx,but the result not expect. Although exit REXX but,return code is zero,not 16.
i think it is ispf service return code.
How to set rc to 16 at final job end?
Can any one give me a sugguestion ?
thanks .

my REXX

Do i = 1 to JobName.0
address ispexec
"lmmfind dataid("did") member("JobName.i") stats(yes)"
if rc = 0 then /* yes,found the job */
Do
JobName_out = LEFT(STRIP(JobName.i),8) /* default pad is blank */
zlchtime = zlmtime || ":" || zlmsec
out_rec = JobName_out zlcnorc zlc4date zlm4date zlchtime,
zluser zlinorc zlvers zlmod
SAY "OUT_REC IS :" OUT_REC
push out_rec
address tso
"EXECIO 1 DISKW JobStats"
job_count = job_count + 1
End
else /* member not found */
Do
Job_err = STRIP(JobName.i)
say "The job" Job_err "not in" SrcLib
Err_msg = "ERR!! The job " || Job_err || " not in " || SrcLib
Call WTO_MSG Err_msg
exit 16
End

JOB LOG
13.32.54 JOB52174 ---- MONDAY, 25 APR 2011 ----
13.32.54 JOB52174 IRR010I USERID BB9G IS ASSIGNED TO THIS JOB.
13.32.54 JOB52174 ICH70001I BB9G LAST ACCESS AT 13:32:27 ON MONDAY, APRIL 2
13.32.54 JOB52174 $HASP373 RX$LMDIR STARTED - INIT 2 - CLASS A - SYS ZST1
13.32.54 JOB52174 IEF403I RX$LMDIR - STARTED - TIME=13.32.54
13.32.58 JOB52174 +OPEN JOBTABLE FILE SUCCESSFUL
13.32.58 JOB52174 +OPEN JOBSTATS FILE SUCCESSFUL
13.32.58 JOB52174 +ERR!! THE JOB AD$DDBKZ NOT IN PN.BATCHLIB
13.32.59 JOB52174 - --TIMINGS (MIN
13.32.59 JOB52174 -JOBNAME STEPNAME PROCSTEP RC EXCP CONN TCB SRB
13.32.59 JOB52174 -RX$LMDIR ISPF 00 410 201 .00 .00
13.32.59 JOB52174 IEF404I RX$LMDIR - ENDED - TIME=13.32.59
13.32.59 JOB52174 -RX$LMDIR ENDED. NAME- TOTAL TCB CPU TIM
13.32.59 JOB52174 $HASP395 RX$LMDIR ENDED

and there are some error in SYSTPRT OUTPUT

ISPD117
The initially invoked CLIST ended with a return code = 16
good123
 
Posts: 8
Joined: Sun Jan 02, 2011 8:35 pm
Has thanked: 0 time
Been thanked: 0 time

Re: REXX AND ISPF RETURN CODE PROBLEM

 

Re: REXX AND ISPF RETURN CODE PROBLEM

Postby expat » Mon Apr 25, 2011 2:44 pm

peut etre ZISPFRC
expat
 
Posts: 383
Joined: Sat Jun 09, 2007 3:21 pm
Has thanked: 0 time
Been thanked: 1 time

Re: REXX AND ISPF RETURN CODE PROBLEM

Postby good123 » Mon Apr 25, 2011 3:24 pm

Dear expat:
thanks. i add two statement,
zispfrc = 16
address ispexec " vput (zispfrc)"

the jcl final rc set to 16,job works fine.
good123
 
Posts: 8
Joined: Sun Jan 02, 2011 8:35 pm
Has thanked: 0 time
Been thanked: 0 time


Return to CLIST & REXX

 


  • Related topics
    Replies
    Views
    Last post