correcting the script so org_unit_setting values are quoted appropriately
authorChris Sharp <csharp@georgialibraries.org>
Wed, 14 Dec 2011 14:50:59 +0000 (09:50 -0500)
committerChris Sharp <csharp@georgialibraries.org>
Wed, 14 Dec 2011 14:50:59 +0000 (09:50 -0500)
Open-ILS/src/sql/Pg/pines-2.1-updates.sql

index 4d7fd6c..9fac26b 100644 (file)
@@ -1,11 +1,11 @@
 -- insert the PINES org_unit_settings that have been created in test environment
 
 BEGIN;
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'cat.default_classification_scheme', '2' );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'cat.default_classification_scheme', $$"2"$$ );
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.dob.require', 'true' );
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.registration.require_address', 'true' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.default_country', 'USA' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.default_ident_type', '1' );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.default_country', $$"USA"$$ );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.default_ident_type', $$"1"$$ );
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.staff.require_initials', 'true' );
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.alert_message.show', 'true' );
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.alias.show', 'false' );
@@ -20,13 +20,14 @@ INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'circ.hol
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'circ.patron_invalid_address_apply_penalty', 'true' );
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'circ.obscure_dob', 'false' );
 INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.circ.show_billing_tab_on_bills', 'true' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.email.example', 'address@example.com' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.evening_phone.example', 'XXX-XXX-XXXX' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.day_phone.example', 'XXX-XXX-XXXX' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.other_phone.example', 'XXX-XXX-XXXX' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.email.regex', '[^@<> ]+@[^@<> ]+\\.[^@.*<> ]{2,}' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.phone.regex', '\\d{3}-\\d{3}-\\d{4}' );
-INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.aua.post_code.regex', '\\d{5}(-\\d{4})?' );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.email.example', $$"address@example.com"$$ );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.evening_phone.example', $$"XXX-XXX-XXXX"$$ );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.day_phone.example', $$"XXX-XXX-XXXX"$$ );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.other_phone.example', $$"XXX-XXX-XXXX"$$ );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.au.email.regex', $$"[^@<> ]+@[^@<> ]+\\.[^@.*<> ]{2,}"$$ );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.phone.regex', $$"\\d{3}-\\d{3}-\\d{4}"$$ );
+INSERT INTO actor.org_unit_setting (org_unit, name, value) VALUES ( 1, 'ui.patron.edit.aua.post_code.regex', $$"\\d{5}(-\\d{4})?"$$ );
+
 COMMIT;
 
 -- insert the new permission groups and assign them their perms.