The DROP_PROGRAM procedure drops a program. When a program is dropped, parameters related to the program are also dropped.
Applicability
This topic applies only to OceanBase Database Enterprise Edition. OceanBase Database Community Edition provides only the MySQL mode.
Syntax
DBMS_SCHEDULER.DROP_PROGRAM (
program_name IN VARCHAR2,
force IN BOOLEAN DEFAULT FALSE);
Parameters
| Parameter | Description |
|---|---|
| program_name | The name of the program to drop. You can specify a list of names and separate them with commas (,). |
| force | If you set force to FALSE, the program must be referenced by no job while being dropped. Otherwise, an error occurs. If you set force to TRUE, all jobs that reference the program are disabled before the program is dropped. The call of the DROP_PROGRAM procedure does not affect the execution of a running job that points to the program. |
Considerations
To drop a program, you must be the owner of the program or have the ALTER privilege on the program. You can also drop the program if you have the CREATE ANY JOB privilege.
Examples
BEGIN
DBMS_SCHEDULER.DROP_PROGRAM(program_name => 'program_test');
END;