Swap the delete and constraint db lines

This commit is contained in:
Yana De Pauw
2024-04-30 16:40:47 +02:00
parent 80a7e48536
commit 435988ca00
2 changed files with 4 additions and 4 deletions

View File

@@ -6,7 +6,7 @@
-- http://www.dspace.org/license/
--
DELETE FROM ResourcePolicy WHERE eperson_id is null and epersongroup_id is null;
ALTER TABLE ResourcePolicy ADD CONSTRAINT resourcepolicy_eperson_and_epersongroup_not_nullobject_chk
CHECK (eperson_id is not null or epersongroup_id is not null) ;
DELETE FROM ResourcePolicy WHERE eperson_id is null and epersongroup_id is null;

View File

@@ -6,7 +6,7 @@
-- http://www.dspace.org/license/
--
DELETE FROM ResourcePolicy WHERE eperson_id is null and epersongroup_id is null;
ALTER TABLE ResourcePolicy ADD CONSTRAINT resourcepolicy_eperson_and_epersongroup_not_nullobject_chk
CHECK (eperson_id is not null or epersongroup_id is not null) ;
DELETE FROM ResourcePolicy WHERE eperson_id is null and epersongroup_id is null;