Joined: 18 May 2005 Posts: 108 Topics: 31 Location: USA
Posted: Mon Mar 23, 2009 12:53 pm Post subject: DB2 SQL Procedures on z/os
Hi Friends,
We are developing a web application which access data through Db2 on z/os. We need to create SQL procedures and when I create the following sql I got -628 sql code on it. Can we have SQL procedures created in DB2 catalogs and can these be called through by CALL statement in Java. We are in version 8 DB2. Please advise.
Code:
CREATE PROCEDURE UPDATE_DRUGS
(IN DMUMNEM CHAR(8)
,IN DAYSNO INTEGER
)
DYNAMIC RESULT SETS 0
LANGUAGE SQL
PARAMETER STYLE GENERAL
MODIFIES SQL DATA
WLM ENVIRONMENT TDB2SID1
STAY RESIDENT YES
COMMIT ON RETURN YES
COLLID ICPC
BEGIN UPDATE IDVPCS01.ITORDSET
SET DURATION = DURATION * DAYSNO
WHERE MNEMONIC = DMUMNEM;
END
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