Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL Stored Procedure Compile with SCLM

Status
Not open for further replies.

sln007

MIS
Nov 14, 2001
129
US
Hi,

The maniframe compiler, via SCLM, can create SQL Stored Procedures, but WITHOUT any "DECLARE EXIT HANDLER...." statements.

If any "DECLARE EXIT HANDLER...." statements are present, the compiler returns the following:

---------------------------------------------------
%DATASET -------- PROC=PC STEP=STEP002 DDNAME=SYSTERM ------------------
DSNH016I E DSNHPARS LINE 65 COL 12 "GLOBAL" REQUIRED
DSNH199I E DSNHPARS LINE 65 COL 12 INVALID KEYWORD "EXIT"; VALID SYMBOLS ARE: GLOBAL
CREATE PROCEDURE WI01PU.ICAV0010(INOUT USERID_IN CHAR(8),INOUT SPNAME CHAR(12),INOUT SQLSTATE_OUT CHAR(5),INOUT SQLCODE_OUT INT)EX
TERNAL NAME ICAV0010 LANGUAGE SQL MODIFIES SQL DATA COLLID WICA01CU WLM ENVIRONMENT DB3ASWI1 ASUTIME NO LIMIT RUN OPTIONS'NOTEST(A
LL,*,,VADTCPIP&10.3.30.127:*)'P1:BEGIN DECLARE SQLSTATE CHAR(5)DEFAULT'00000';DECLARE SQLCODE INT DEFAULT 0;DECLARE ENDTABLE INT D
EFAULT 0;SET SPNAME='ICAV0010_001';UPDATE WI01PU.COA_ADRC_SUS S SET SUSPEND_NBR=0,EXCEPT_NBR=0 WHERE(S.SUSPEND_NBR<>0 OR S.EXCEPT_
NBR<>0)AND EXISTS(SELECT U.USERID FROM WI01PU.ACR_USER_PARM U,WI01PU.CAP_VRSN_CNTL V WHERE U.USERID=USERID_IN AND S.CAP_VRSN_KEY=U
.CAP_VRSN_KEY AND V.CAP_VRSN_KEY=U.CAP_VRSN_KEY AND V.STATUS_CD='P');DECLARE EXIT

---------------------------------------------
Can anyone suggest a solution?

Steve N.
State of Ohio, MIS
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top