pnbalaji Beginner
Joined: 05 Oct 2004 Posts: 14 Topics: 8 Location: Chennai, India
|
Posted: Tue Oct 05, 2004 2:09 pm Post subject: REXX with ISPF Panel |
|
|
Hi,
I have coded a REXX exec to generate the DB2 REPAIR jcl. The inputs
are taken from an ISPF panel. I have a strange issue. The REXX exec is
working fine in my PC most of the times (but not all times). However,
it is not working in my friend's PC. Another issue I have is when I
execute the exec, the LIBDEF statements are causing some problems ( I
guess the NULL LIBDEF statement at line #7 is the one that is causing
problems) and I am not able to execute SPUFI. SPUFI asks for the DB2
subsystem before I enter the SQL query. I am pasting both the REXX
code and the ISPF panel code. Can some one tell me how to fix the
above issues?. It would be better if someone has time to re-write the
piece of code.
I have some more questions that are listed below.
1. Is it necessary to use the VPUT statement in the ISPF panel PROC
to save the variables that I enter in the dialog?.
2. When should I use NEWAPPL and PASSLIB commands?.
REXX EXEC CODE:
Code: |
---------------
===============================================/******************** REXX *****************************************
ADDRESS ISPEXEC
"CONTROL ERRORS RETURN"
"LIBDEF ISPPLIB DATASET ID('TSO.BNEELKA.PANELS') STACK"
"DISPLAY PANEL(REPAIR)"
DISPLAY_RC = RC
"VGET (DB2SUB CREATOR TBLNAME) SHARED"
"LIBDEF ISPPLIB"
O = MSG("OFF")
USER = USERID()
REG = WORD(DB2SUB,1)
CRT = WORD(CREATOR,1)
TBL = WORD(TBLNAME,1)
CALL BUILD'JCL
===============================================
ISPF PANEL CODE:
----------------
===============================================)BODY
%--------------- REXX EXEC TO CREATE DB2 REPAIR JOB
-------------------
%
+LOGGED ON USER=====>%&ZUSER
%
%
%1. ENTER DB2 SUBSYSTEM ====>_DB2SUB +
%
%2. ENTER TABLE CREATOR ====>_CREATOR +
%
%3. ENTER TABLE NAME ====>_TBLNAME +
%
)INIT
.HELP = REPHELP
&DB2SUB = ''
&CREATOR = ''
&TBLNAME = ''
)PROC
VER (&DB2SUB,NONBLANK)
VER (&CREATOR,NONBLANK)
VER (&TBLNAME,NONBLANK)
"VPUT (DB2SUB CREATOR TBLNAME) SHARED"
)END
===============================================
|
Thanks,
Balaji. |
|