Search
 
SCRIPT & CODE EXAMPLE
 

SQL

oracle drop type if exists

DECLARE
    existing_type number;
BEGIN
    SELECT count(*) into existing_type
    FROM ALL_TYPES
    WHERE TYPE_NAME = 'type_name' AND OWNER = 'schema_name';
    IF existing_type = 1 then
        EXECUTE IMMEDIATE 'DROP TYPE schema_name.type_name';
    END IF;
END;
Comment

PREVIOUS NEXT
Code Example
Sql :: SQL Server OPENJSON FROM table column 
Sql :: alter table drop partition hive 
Sql :: mysql dump 
Sql :: declare date variable sql 
Sql :: divide by zero error in sql 
Sql :: mysql like 
Sql :: multiple row primary key 
Sql :: mysql generate create table script 
Sql :: ORACLE sql join multiple tables 
Sql :: 2 max value in sql 
Sql :: coalesce function in sql server 
Sql :: create-table 
Sql :: sql highest salary by location 
Sql :: sql server inner join convert collation 
Sql :: get specific column in mongodb 
Sql :: how to add more columns to a table in mysql 
Sql :: select where mysql 
Sql :: mysql autoincrement valor inicial 
Sql :: cara menampilkan user di mysql terminal 
Sql :: sql contains vs like 
Sql :: stuff in sql server 
Sql :: cascade syntax in sql 
Sql :: make selected text uppercase mssql 
Sql :: mysql join column order By and group By 
Sql :: identify rows with 2 same column value and delete duplicate mysql 
Sql :: denormalization in sql example 
Sql :: convert .mdf to .bak 
Sql :: mysql allow connection from any host 
Sql :: delete sql 
Sql :: PG::ForeignKeyViolation: ERROR: update or delete on table violates foreign key constraint 
ADD CONTENT
Topic
Content
Source link
Name
2+6 =