From: erickson Date: Tue, 19 Jan 2010 17:02:13 +0000 (+0000) Subject: move the removal of an optional trigger outside the transaction so it won't fail... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=6692fea32e92b77356140b11782c87e964b848f1;p=Evergreen.git move the removal of an optional trigger outside the transaction so it won't fail and roll back the transaction when the trigger is not present git-svn-id: svn://svn.open-ils.org/ILS/trunk@15340 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/sql/Pg/upgrade/0136.schema.in-db-ingest.sql b/Open-ILS/src/sql/Pg/upgrade/0136.schema.in-db-ingest.sql index 1361d349dc..c18518dfd5 100644 --- a/Open-ILS/src/sql/Pg/upgrade/0136.schema.in-db-ingest.sql +++ b/Open-ILS/src/sql/Pg/upgrade/0136.schema.in-db-ingest.sql @@ -357,9 +357,6 @@ BEGIN END; $func$ LANGUAGE PLPGSQL; --- Ingest triggers -DROP TRIGGER zzz_update_materialized_simple_rec_delete_tgr ON biblio.record_entry; - CREATE OR REPLACE FUNCTION reporter.simple_rec_trigger () RETURNS TRIGGER AS $func$ BEGIN IF TG_OP = 'DELETE' THEN @@ -377,3 +374,8 @@ CREATE TRIGGER aaa_indexing_ingest_or_delete AFTER INSERT OR UPDATE ON biblio.re CREATE TRIGGER bbb_simple_rec_trigger AFTER INSERT OR UPDATE ON biblio.record_entry FOR EACH ROW EXECUTE PROCEDURE reporter.simple_rec_trigger (); COMMIT; + +-- Ingest triggers. Not installed on all systems. Delete outside the transaction +DROP TRIGGER zzz_update_materialized_simple_rec_delete_tgr ON biblio.record_entry; + +