Valid in: SQL, ESQL
The Drop Procedure statement removes a database procedure definition from the database. Sessions that are executing the procedure are allowed to complete before the procedure's query plan is removed from memory.
If a procedure that is executed from another procedure is removed, the calling procedure is retained but marked dormant, and cannot be executed until the called procedure is restored.
The Drop Procedure statement has the following format:
[EXEC SQL] DROP PROCEDURE proc_name;
Specifies the name of the procedure to be removed.
In an embedded Drop Procedure statement, a host language variable cannot be used to represent proc_name.
You must be the owner of a database procedure.
The following example removes the procedure named salupdt:
drop procedure salupdt;