Chapter 3: Stored Procedures

This chapter describes the type of support HCO provides when using DB2 Universal Database stored procedures under Mainframe Express.

DB2 Universal Database supports using stored procedures written in many languages including COBOL, C++, JAVA and now SQL Procedure Language (SPL). However, DB2 Universal Database requires COBOL stored procedures to be built as DLL's which Mainframe Express does not allow you to build. Therefore, if you want to build COBOL DLL's, you must use our Net Express product. The Net Express Database Access manual has a chapter devoted to building and testing DB2 stored procedures.

HCO does support compiling and testing the client part in COBOL and has successully tested stored procedures written in:

as well as COBOL stored procedures built with Net Express.

3.1 SQL Syntax Not Supported

DB2 Universal Database does not support all stored procedure SQL syntax under COBOL at this time. SQL syntax that involves result set locators are only currently supported in programs written in C++ or JAVA.

Please check your DB2 SQL Reference and DB2 Application Development Guide to see if COBOL support has been added for this syntax.

The following syntax is not supported in COBOL:

3.2 Other Alternatives

If you are porting or testing application to/from DB2 for OS/390 and you want to use COBOL stored procedures without using Net Express or use SQL syntax not supported by DB2 Universal Database, Mainframe Express does provide an alternative. You can use SQL Option for DB2 (XDB).

SQL Option supports the above listed syntax as well and allows stored procedures to be built and debugged using either INT or GNT code. See the SQL Option manuals for further details.


Copyright © 2001 Micro Focus International Limited. All rights reserved.
This document and the proprietary marks and names used herein are protected by international law.