Search
 
SCRIPT & CODE EXAMPLE
 

SQL

oracle create program if not exists

DECLARE
    existing_program NUMBER;
BEGIN
    SELECT count(*) INTO existing_program
    FROM ALL_SCHEDULER_PROGRAMS WHERE PROGRAM_NAME = 'prog_name' AND OWNER='owner';
    IF existing_program = 1 THEN
        dbms_scheduler.DROP_PROGRAM(PROGRAM_NAME => 'prog_name');
    END IF;
END;
/
BEGIN DBMS_SCHEDULER.create_program(program_name => 'owner.prog_name', ...); END;
Comment

PREVIOUS NEXT
Code Example
Sql :: having vs where sql 
Sql :: sql query to find duplicate email address 
Sql :: postgres date difference seconds 
Sql :: script to add new column in table sql 
Sql :: oracle add column with default value 
Sql :: alter table 
Sql :: return insert results in POSTGRESQL 
Sql :: backup ms sql database table data to file 
Sql :: ora-00054 find lock 
Sql :: how to delete git repo locally 
Sql :: sql server date now 
Sql :: reset identity column values in sql server 
Sql :: mysql output csv 
Sql :: add auto increment column mysql 
Sql :: size of all tables in a schema oracle 
Sql :: where date major today mysql 
Sql :: oracle limit rows 
Sql :: how to alter length character varying postgres 
Sql :: where not in array sql 
Sql :: sql delete join 
Sql :: How to convert Varchar to Double in sql? 
Sql :: sql in sublime 
Sql :: trim leading zeros in sql 
Sql :: shrink database file in sql server 
Sql :: wordpress delete post revisions older than date "sql" 
Sql :: mysql date time string format python 
Sql :: drop index oracle 
Sql :: mysql average of multiple columns 
Sql :: regex mongoose 
Sql :: sql add two values together 
ADD CONTENT
Topic
Content
Source link
Name
7+3 =