Missing foreign keys

This commit is contained in:
Carlos Ruiz 2017-10-31 22:30:15 +01:00
parent 8594b12001
commit 106f06e607
2 changed files with 36 additions and 0 deletions

View File

@ -0,0 +1,18 @@
-- missing foreign keys
ALTER TABLE AD_Column ADD CONSTRAINT PADashboardContent_ADColumn FOREIGN KEY (PA_DashboardContent_ID) REFERENCES PA_DashboardContent DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_CtxHelpSuggestion ADD CONSTRAINT ADUserClient_ADCtxHelpSuggesti FOREIGN KEY (AD_UserClient_ID) REFERENCES AD_AllClients_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_CtxHelpSuggestion ADD CONSTRAINT ADUser_ADCtxHelpSuggestion FOREIGN KEY (AD_User_ID) REFERENCES AD_AllUsers_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_FieldSuggestion ADD CONSTRAINT ADUserClient_ADFieldSuggestion FOREIGN KEY (AD_UserClient_ID) REFERENCES AD_AllClients_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_FieldSuggestion ADD CONSTRAINT ADUser_ADFieldSuggestion FOREIGN KEY (AD_User_ID) REFERENCES AD_AllUsers_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_PInstance ADD CONSTRAINT ADLanguage_ADPInstance FOREIGN KEY (AD_Language_ID) REFERENCES AD_Language DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_WF_Node ADD CONSTRAINT ADInfoWindow_ADWFNode FOREIGN KEY (AD_InfoWindow_ID) REFERENCES AD_InfoWindow DEFERRABLE INITIALLY DEFERRED;
SELECT register_migration_script('201710312225_MissingForeignKeys.sql') FROM dual
;

View File

@ -0,0 +1,18 @@
-- missing foreign keys
ALTER TABLE AD_Column ADD CONSTRAINT PADashboardContent_ADColumn FOREIGN KEY (PA_DashboardContent_ID) REFERENCES PA_DashboardContent DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_CtxHelpSuggestion ADD CONSTRAINT ADUserClient_ADCtxHelpSuggesti FOREIGN KEY (AD_UserClient_ID) REFERENCES AD_AllClients_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_CtxHelpSuggestion ADD CONSTRAINT ADUser_ADCtxHelpSuggestion FOREIGN KEY (AD_User_ID) REFERENCES AD_AllUsers_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_FieldSuggestion ADD CONSTRAINT ADUserClient_ADFieldSuggestion FOREIGN KEY (AD_UserClient_ID) REFERENCES AD_AllClients_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_FieldSuggestion ADD CONSTRAINT ADUser_ADFieldSuggestion FOREIGN KEY (AD_User_ID) REFERENCES AD_AllUsers_V DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_PInstance ADD CONSTRAINT ADLanguage_ADPInstance FOREIGN KEY (AD_Language_ID) REFERENCES AD_Language DEFERRABLE INITIALLY DEFERRED;
ALTER TABLE AD_WF_Node ADD CONSTRAINT ADInfoWindow_ADWFNode FOREIGN KEY (AD_InfoWindow_ID) REFERENCES AD_InfoWindow DEFERRABLE INITIALLY DEFERRED;
SELECT register_migration_script('201710312225_MissingForeignKeys.sql') FROM dual
;