Create Procedure (DB2 Stored Procedure structure)

A stored procedure in DB2 has the following structure:

 CREATE PROCEDURE [OR REPLACE] <procname> [ ( {optional parameters} ) ]
 [{optional procedure attributes}]
 BEGIN [atomic]
   ... statements ...

The following optional procedure attributes are supported:

A procedure can be defined as ATOMIC or NON-ATOMIC procedure.
The OR REPLACE option is available with DB2 9.7.

The declaration of variables, the statements, and procedure logic is placed in the procedure body.

…coming soon…


Link to the DB2 Information Center: DB2 9.7 DB2 10.1 DB2 10.5