Bug 17767: Add borrower_modification.extended_attributes
authorTomas Cohen Arazi <tomascohen@theke.io>
Tue, 13 Dec 2016 20:42:35 +0000 (17:42 -0300)
committerKyle M Hall <kyle@bywatersolutions.com>
Wed, 28 Dec 2016 13:53:01 +0000 (13:53 +0000)
This patch changes the DB structure adding borrower_modifications.extended_attributes

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
installer/data/mysql/atomicupdate/bug_extended_attr_modification.sql [new file with mode: 0644]
installer/data/mysql/kohastructure.sql

diff --git a/installer/data/mysql/atomicupdate/bug_extended_attr_modification.sql b/installer/data/mysql/atomicupdate/bug_extended_attr_modification.sql
new file mode 100644 (file)
index 0000000..58c1253
--- /dev/null
@@ -0,0 +1,12 @@
+ALTER TABLE borrower_modifications ADD COLUMN extended_attributes text DEFAULT NULL AFTER privacy;
+
+-- $DBversion = "16.12.00.XXX";
+-- if ( CheckVersion($DBversion) ) {
+--
+--     $dbh->do( "ALTER TABLE borrower_modifications
+--                      ADD COLUMN extended_attributes text DEFAULT NULL
+--                      AFTER privacy" );
+--     print "Upgrade to $DBversion done (Bug 8835). Everything is fine.\n";
+--
+--     SetVersion($DBversion);
+-- }
index 514c13d..f40692e 100644 (file)
@@ -3424,6 +3424,7 @@ CREATE TABLE IF NOT EXISTS `borrower_modifications` (
   `altcontactphone` varchar(50) DEFAULT NULL,
   `smsalertnumber` varchar(50) DEFAULT NULL,
   `privacy` int(11) DEFAULT NULL,
+  `extended_attributes` text DEFAULT NULL,
   PRIMARY KEY (`verification_token`,`borrowernumber`),
   KEY `verification_token` (`verification_token`),
   KEY `borrowernumber` (`borrowernumber`)