DROP PROCEDURE

The DROP PROCEDURE statement drops a procedure from your database. Procedures are added to the database with the CREATE PROCEDURE statement.

Syntax

DROP PROCEDURE procedure-name

procedure-Name

The name of the procedure that you want to drop from your database.

Usage

Use this statement to drop a statement from your database. It is valid only if there is exactly one procedure instance with the procedure-name in the schema. The specified procedure can have any number of parameters defined for it.

An error will occur in any of the following circumstances:

  • If no procedure with the indicated name exists in the named or implied schema (the error is SQLSTATE 42704)
  • If there is more than one specific instance of the procedure in the named or implied schema
  • If you try to drop a user-defined procedure that is invoked in the generation-clause of a generated column
  • If you try to drop a user-defined procedure that is invoked in a view

Example

splice> DROP PROCEDURE SALES.TOTAL_REVENUE;
0 rows inserted/updated/deleted

See Also