From 3ed20ce9fc08902823a81fc3674d680b6ea7fd62 Mon Sep 17 00:00:00 2001 From: Steven Callender Date: Wed, 27 Apr 2016 12:05:48 -0400 Subject: [PATCH] LP#1569884 Updated base schema with monograph parts index. Signed-off-by: Steven Callender Signed-off-by: Jason Stephenson Signed-off-by: Galen Charlton --- Open-ILS/src/sql/Pg/010.schema.biblio.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Open-ILS/src/sql/Pg/010.schema.biblio.sql b/Open-ILS/src/sql/Pg/010.schema.biblio.sql index ff0542d21d..3312edfc7f 100644 --- a/Open-ILS/src/sql/Pg/010.schema.biblio.sql +++ b/Open-ILS/src/sql/Pg/010.schema.biblio.sql @@ -99,8 +99,8 @@ CREATE TABLE biblio.monograph_part ( label TEXT NOT NULL, label_sortkey TEXT NOT NULL, deleted BOOL NOT NULL DEFAULT FALSE, - CONSTRAINT record_label_unique UNIQUE (record,label) ); +CREATE UNIQUE INDEX CONCURRENTLY record_label_unique_idx ON biblio.monograph_part (record, label) WHERE deleted = FALSE; CREATE OR REPLACE FUNCTION biblio.normalize_biblio_monograph_part_sortkey () RETURNS TRIGGER AS $$ BEGIN -- 2.11.0