LP#1519055: Stamping upgrade script for electronic resources filter
authorBen Shum <ben@evergreener.net>
Wed, 2 Mar 2016 02:25:40 +0000 (21:25 -0500)
committerBen Shum <ben@evergreener.net>
Wed, 2 Mar 2016 02:25:40 +0000 (21:25 -0500)
Signed-off-by: Ben Shum <ben@evergreener.net>
Open-ILS/src/sql/Pg/002.schema.config.sql
Open-ILS/src/sql/Pg/upgrade/0964.data.electronic-resources.sql [new file with mode: 0644]
Open-ILS/src/sql/Pg/upgrade/XXX.data.electronic-resources.sql [deleted file]

index edb2de6..544eb7a 100644 (file)
@@ -91,7 +91,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 ('0963', :eg_version); -- jboyer/bshum
+INSERT INTO config.upgrade_log (version, applied_to) VALUES ('0964', :eg_version); -- jlitrell/kmlussier/bshum
 
 CREATE TABLE config.bib_source (
        id              SERIAL  PRIMARY KEY,
diff --git a/Open-ILS/src/sql/Pg/upgrade/0964.data.electronic-resources.sql b/Open-ILS/src/sql/Pg/upgrade/0964.data.electronic-resources.sql
new file mode 100644 (file)
index 0000000..b1ba02a
--- /dev/null
@@ -0,0 +1,33 @@
+BEGIN;
+
+SELECT evergreen.upgrade_deps_block_check('0964', :eg_version);
+
+INSERT INTO config.coded_value_map
+    (id, ctype, code, opac_visible, value, search_label) VALUES
+(712, 'search_format', 'electronic', FALSE,
+    oils_i18n_gettext(712, 'Electronic', 'ccvm', 'value'),
+    oils_i18n_gettext(712, 'Electronic', 'ccvm', 'search_label'));
+
+INSERT INTO config.composite_attr_entry_definition
+    (coded_value, definition) VALUES
+(712, '[{"_attr":"item_form","_val":"s"},{"_attr":"item_form","_val":"o"}]');
+
+
+COMMIT;
+
+\qecho To use the new electronic search format, it is necessary to do a
+\qecho record attribute reingest. Consider generating an SQL script with
+\qecho the following queries:
+\qecho
+\qecho '\\t'
+\qecho '\\o /tmp/partial_reingest_bib_recs.sql'
+\qecho 'SELECT ''select metabib.reingest_record_attributes('' || id || '');'' FROM biblio.record_entry WHERE NOT DELETED AND id > 0;'
+\qecho '\\o'
+\qecho '\\t'
+\qecho
+\qecho
+\qecho **** then running it via psql:
+\qecho
+\qecho
+\qecho '\\i /tmp/partial_reingest_bib_recs.sql'
+\qecho
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXX.data.electronic-resources.sql b/Open-ILS/src/sql/Pg/upgrade/XXX.data.electronic-resources.sql
deleted file mode 100644 (file)
index b634c36..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-BEGIN;
-
-SELECT evergreen.upgrade_deps_block_check('XXX', :eg_version);
-
-INSERT INTO config.coded_value_map
-    (id, ctype, code, opac_visible, value, search_label) VALUES
-(712, 'search_format', 'electronic', FALSE,
-    oils_i18n_gettext(712, 'Electronic', 'ccvm', 'value'),
-    oils_i18n_gettext(712, 'Electronic', 'ccvm', 'search_label'));
-
-INSERT INTO config.composite_attr_entry_definition
-    (coded_value, definition) VALUES
-(712, '[{"_attr":"item_form","_val":"s"},{"_attr":"item_form","_val":"o"}]');
-
-
-COMMIT;
-
-\qecho To use the new electronic search format, it is necessary to do a
-\qecho record attribute reingest. Consider generating an SQL script with
-\qecho the following queries:
-\qecho
-\qecho '\\t'
-\qecho '\\o /tmp/partial_reingest_bib_recs.sql'
-\qecho 'SELECT ''select metabib.reingest_record_attributes('' || id || '');'' FROM biblio.record_entry WHERE NOT DELETED AND id > 0;'
-\qecho '\\o'
-\qecho '\\t'
-\qecho
-\qecho
-\qecho **** then running it via psql:
-\qecho
-\qecho
-\qecho '\\i /tmp/partial_reingest_bib_recs.sql'
-\qecho