This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE OR REPLACE PROCEDURE "CLEANOUT" AS | |
-- Drop FK restraints (type = ''R') so tables can be dropped in any order | |
cursor con_cursor IS | |
SELECT rtrim(constraint_name) as conname, rtrim(table_name) as tabname | |
FROM user_constraints | |
WHERE rtrim(constraint_type) = 'R'; | |
-- Leave some objects to prevent problems when objects are dropped out of order | |
-- Do not drop indexes, they will go with tables |