Which statement is valid when removing procedures?
-
Use a drop procedure statement to drop a standalone procedure
-
Use a drop procedure statement to drop a procedure that is part of a package.Then recompile the package specification
-
Use a drop procedure statement to drop a procedure that is part of a package.Then recompile the package body
-
For faster removal and re-creation, do not use a drop procedure statement. Instead, recompile the procedure using the alter procedure statement with the REUSE SETTINGS clause.
The DROP PROCEDURE statement is used to remove standalone procedures in Oracle. For procedures that are part of a package, you cannot drop them individually - you must drop or recompile the entire package. The ALTER PROCEDURE statement with REUSE SETTINGS is used for recompiling, not for dropping procedures.
A standalone stored procedure (not part of a package) is removed with a plain DROP PROCEDURE statement. Procedures inside a package can't be dropped individually — you'd have to edit and recompile the whole package body, since the package's procedures are defined together as a single compiled unit.