Stamping upgrade script for making state not required in org unit address
authorBen Shum <bshum@biblio.org>
Fri, 12 Jul 2013 19:36:06 +0000 (15:36 -0400)
committerBen Shum <bshum@biblio.org>
Fri, 12 Jul 2013 19:37:58 +0000 (15:37 -0400)
Signed-off-by: Ben Shum <bshum@biblio.org>
Open-ILS/src/sql/Pg/002.schema.config.sql
Open-ILS/src/sql/Pg/upgrade/0809.schema.org-addr-state-null.sql [new file with mode: 0644]
Open-ILS/src/sql/Pg/upgrade/XXXX.schema.org-addr-state-null.sql [deleted file]

index 8eae7a7..9b831b9 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 ('0807', :eg_version); -- tsbere/phasefx
+INSERT INTO config.upgrade_log (version, applied_to) VALUES ('0809', :eg_version); -- paxed/bshum
 
 CREATE TABLE config.bib_source (
        id              SERIAL  PRIMARY KEY,
diff --git a/Open-ILS/src/sql/Pg/upgrade/0809.schema.org-addr-state-null.sql b/Open-ILS/src/sql/Pg/upgrade/0809.schema.org-addr-state-null.sql
new file mode 100644 (file)
index 0000000..51a215a
--- /dev/null
@@ -0,0 +1,8 @@
+BEGIN;
+
+SELECT evergreen.upgrade_deps_block_check('0809', :eg_version);
+
+ALTER TABLE actor.org_address ALTER COLUMN state DROP NOT NULL;
+
+COMMIT;
+
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.org-addr-state-null.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.org-addr-state-null.sql
deleted file mode 100644 (file)
index 86d8bf3..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-BEGIN;
-
-ALTER TABLE actor.org_address ALTER COLUMN state DROP NOT NULL;
-
-COMMIT;
\ No newline at end of file