LP#1905091: stamp DB update
authorGalen Charlton <gmc@equinoxinitiative.org>
Fri, 2 Apr 2021 21:55:09 +0000 (17:55 -0400)
committerGalen Charlton <gmc@equinoxinitiative.org>
Fri, 2 Apr 2021 21:55:09 +0000 (17:55 -0400)
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Open-ILS/src/sql/Pg/002.schema.config.sql
Open-ILS/src/sql/Pg/upgrade/1259.data.lp1905091.missing_print_email_trigger_environment.sql [new file with mode: 0644]
Open-ILS/src/sql/Pg/upgrade/XXXX.data.lp1905091.missing_print_email_trigger_environment.sql [deleted file]

index 7939630..a7dfd74 100644 (file)
@@ -92,7 +92,7 @@ CREATE TRIGGER no_overlapping_deps
     BEFORE INSERT OR UPDATE ON config.db_patch_dependencies
     FOR EACH ROW EXECUTE PROCEDURE evergreen.array_overlap_check ('deprecates');
 
-INSERT INTO config.upgrade_log (version, applied_to) VALUES ('1258', :eg_version); -- berick/gcollum/sandbergja
+INSERT INTO config.upgrade_log (version, applied_to) VALUES ('1259', :eg_version); -- mmorgan/JBoyer/gmcharlt
 
 CREATE TABLE config.bib_source (
        id              SERIAL  PRIMARY KEY,
diff --git a/Open-ILS/src/sql/Pg/upgrade/1259.data.lp1905091.missing_print_email_trigger_environment.sql b/Open-ILS/src/sql/Pg/upgrade/1259.data.lp1905091.missing_print_email_trigger_environment.sql
new file mode 100644 (file)
index 0000000..3614c09
--- /dev/null
@@ -0,0 +1,23 @@
+BEGIN;
+
+SELECT evergreen.upgrade_deps_block_check('1259', :eg_version);
+
+INSERT INTO action_trigger.environment (event_def,path)
+SELECT id,'items' from action_trigger.event_definition WHERE name='biblio.record_entry.print.full'
+AND NOT EXISTS (SELECT 1 FROM action_trigger.environment WHERE
+event_def=(SELECT id FROM action_trigger.event_definition WHERE name ='biblio.record_entry.print.full' AND owner=1 LIMIT 1)
+AND path='items');
+
+INSERT INTO action_trigger.environment (event_def,path)
+SELECT id,'items' from action_trigger.event_definition WHERE name='biblio.record_entry.email.full'
+AND NOT EXISTS (SELECT 1 FROM action_trigger.environment WHERE
+event_def=(SELECT id FROM action_trigger.event_definition WHERE name ='biblio.record_entry.email.full' AND owner=1 LIMIT 1)
+AND path='items');
+
+INSERT INTO action_trigger.environment (event_def,path)
+SELECT id,'owner' from action_trigger.event_definition WHERE name='biblio.record_entry.email.full'
+AND NOT EXISTS (SELECT 1 FROM action_trigger.environment WHERE
+event_def=(SELECT id FROM action_trigger.event_definition WHERE name ='biblio.record_entry.email.full' AND owner=1 LIMIT 1)
+AND path='owner');
+
+COMMIT;
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lp1905091.missing_print_email_trigger_environment.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.data.lp1905091.missing_print_email_trigger_environment.sql
deleted file mode 100644 (file)
index a014793..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-BEGIN;
-
-SELECT evergreen.upgrade_deps_block_check('XXXX', :eg_version);
-
-INSERT INTO action_trigger.environment (event_def,path)
-SELECT id,'items' from action_trigger.event_definition WHERE name='biblio.record_entry.print.full'
-AND NOT EXISTS (SELECT 1 FROM action_trigger.environment WHERE
-event_def=(SELECT id FROM action_trigger.event_definition WHERE name ='biblio.record_entry.print.full' AND owner=1 LIMIT 1)
-AND path='items');
-
-INSERT INTO action_trigger.environment (event_def,path)
-SELECT id,'items' from action_trigger.event_definition WHERE name='biblio.record_entry.email.full'
-AND NOT EXISTS (SELECT 1 FROM action_trigger.environment WHERE
-event_def=(SELECT id FROM action_trigger.event_definition WHERE name ='biblio.record_entry.email.full' AND owner=1 LIMIT 1)
-AND path='items');
-
-INSERT INTO action_trigger.environment (event_def,path)
-SELECT id,'owner' from action_trigger.event_definition WHERE name='biblio.record_entry.email.full'
-AND NOT EXISTS (SELECT 1 FROM action_trigger.environment WHERE
-event_def=(SELECT id FROM action_trigger.event_definition WHERE name ='biblio.record_entry.email.full' AND owner=1 LIMIT 1)
-AND path='owner');
-
-COMMIT;