602SQL Documentation Index  

Routine Declaration

routine_declaration ::= DECLARE { procedure_description | function_description };

Routine declaration defines a local procedure or function, that may be called as a SQL statement. Routine declared inside a statement block may only be called inside this block and is deleted when leaving this block.

Globally accessible routines may be created by the CREATE PROCEDURE and CREATE FUNCTION statements.

Variations from the SQL Standard