[open-ils-commits] r15879 - branches/rel_1_6_0/Open-ILS/src/sql/Pg (miker)
svn at svn.open-ils.org
svn at svn.open-ils.org
Wed Mar 17 15:14:12 EDT 2010
Author: miker
Date: 2010-03-17 15:14:07 -0400 (Wed, 17 Mar 2010)
New Revision: 15879
Modified:
branches/rel_1_6_0/Open-ILS/src/sql/Pg/010.schema.biblio.sql
Log:
delete the metarecord link for "deleted" records
Modified: branches/rel_1_6_0/Open-ILS/src/sql/Pg/010.schema.biblio.sql
===================================================================
--- branches/rel_1_6_0/Open-ILS/src/sql/Pg/010.schema.biblio.sql 2010-03-17 19:10:20 UTC (rev 15878)
+++ branches/rel_1_6_0/Open-ILS/src/sql/Pg/010.schema.biblio.sql 2010-03-17 19:14:07 UTC (rev 15879)
@@ -48,7 +48,7 @@
CREATE INDEX biblio_record_entry_fp_idx ON biblio.record_entry ( fingerprint );
CREATE UNIQUE INDEX biblio_record_unique_tcn ON biblio.record_entry (tcn_value) WHERE deleted IS FALSE;
-CREATE RULE protect_bib_rec_delete AS ON DELETE TO biblio.record_entry DO INSTEAD UPDATE biblio.record_entry SET deleted = TRUE WHERE OLD.id = biblio.record_entry.id;
+CREATE RULE protect_bib_rec_delete AS ON DELETE TO biblio.record_entry DO INSTEAD (UPDATE biblio.record_entry SET deleted = TRUE WHERE OLD.id = biblio.record_entry.id; DELETE FROM metabib.metarecord_source_map WHERE source = OLD.id);
CREATE TABLE biblio.record_note (
More information about the open-ils-commits
mailing list