Stored Procedures and DB2
Unfortunately, IBM doesn't provide a simple way of calling a stored procedure from TSO using SPUFI or some other command line mode. However, you can test the stored procedure from your client if you have DB2 Connect installed or Data Studio with a license to connect to z/OS.
To determine which databases and tablespaces are in a restrictive state, issue this from the DB2 command line:
call sysproc.admin_command_db2('-dis db(*) sp(*) restrict limit(*)', 34,TS,null,?,?,?,?,?,?,?,?)
(Note: The third parameter, TS, instructs the stored procedure to parse the string in parameter 1 as a –DISPLAY DATABASE (*) SPACENAM(*) statement and return table space information.)
To learn which IBM administrative procedures are installed, query the DB2 catalog. The following query can be used to list all install procedures owned by SYSPROC, which is usually the schema owner for these procedures:
SELECT SUBSTR(SCHEMA,1,8) AS SCHEMA
, SUBSTR(NAME,1,18) AS NAME
FROM SYSIBM.SYSROUTINES
WHERE SCHEMA = 'SYSPROC'
ORDER BY SCHEMA, NAME
If you use these procedures in your application, please respond in Comments.
Connect With Us: