This discussion is archived
5 Replies Latest reply: Mar 14, 2013 9:02 AM by Em RSS

QUICK_DDL issue; all FK constraints added before PL/SQL source

user451977 Newbie
Currently Being Moderated
After installing version 3.2.10.09 I noticed that QUICK_DDL took minutes where it used to take seconds in 3.2.09 and I also noticed that the generated files were a lot bigger. The reason is easy to spot: every single file generated for stored PL/SQL starts with the DDL for all Foreign Key Constraints defined in the schema! This is an example for a very small schema with hardly any tables or constraints:

--------------------------------------------------------
-- File created - dinsdag-september-25-2012
--------------------------------------------------------
--------------------------------------------------------
-- Ref Constraints for Table GESDB4COLS
--------------------------------------------------------

ALTER TABLE "GESDB4COLS" ADD CONSTRAINT "GDB4C_FK1" FOREIGN KEY ("SCHEMANAME", "TABLENAME")
     REFERENCES "GESDB4TABS" ("SCHEMANAME", "TABLENAME") ENABLE

ALTER TABLE "GESDB4COLS" ADD CONSTRAINT "GDB4C_FK2" FOREIGN KEY ("SOURCESCHEMA", "SOURCETABLE", "SOURCECOL")
     REFERENCES "GESDB3COLS" ("SCHEMANAME", "TABLENAME", "COLNAME") ENABLE
/
--------------------------------------------------------
-- DDL for Package MIGRATION
--------------------------------------------------------

CREATE OR REPLACE PACKAGE "MIGRATION" AUTHID CURRENT_USER AS

-- 27 April 2006 Initial creation by
-- AUTHID CURRENT_USER needed according to note 312883.1

PROCEDURE match_columns;
PROCEDURE generate_migration(t_or_p VARCHAR2 := 'TEST');

PROCEDURE runprod;
PROCEDURE runtest;
PROCEDURE runsqlsteps;

PROCEDURE verify_possible_html;
PROCEDURE verify_possible_dbms;

PROCEDURE setup_migration;
PROCEDURE setup_full_migration;

END migration;
/

Running the previous version using exactly the same setup, produces the correct file without all the constraint definitions.