Browse Source

Bug 19670: DBRev 18.12.00.041

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
19.05.x
Nick Clemens 5 years ago
parent
commit
f7869ad48b
  1. 2
      Koha.pm
  2. 13
      installer/data/mysql/atomicupdate/bug_19670.perl
  3. 14
      installer/data/mysql/updatedatabase.pl

2
Koha.pm

@ -29,7 +29,7 @@ use vars qw{ $VERSION };
# - #4 : the developer version. The 4th number is the database subversion.
# used by developers when the database changes. updatedatabase take care of the changes itself
# and is automatically called by Auth.pm when needed.
$VERSION = "18.12.00.040";
$VERSION = "18.12.00.041";
sub version {
return $VERSION;

13
installer/data/mysql/atomicupdate/bug_19670.perl

@ -1,13 +0,0 @@
$DBversion = 'XXX'; # will be replaced by the RM
if( CheckVersion( $DBversion ) ) {
my $table_sth = $dbh->prepare('SHOW CREATE TABLE `search_marc_map`');
$table_sth->execute();
my @table = $table_sth->fetchrow_array();
unless ( $table[1] =~ /`marc_field`.*COLLATE utf8mb4_bin/ ) { #catches utf8mb4 collated tables
$dbh->do("ALTER TABLE `search_marc_map` MODIFY `marc_field` VARCHAR(255) NOT NULL COLLATE utf8mb4_bin COMMENT 'the MARC specifier for this field'");
}
# Always end with this (adjust the bug info)
SetVersion( $DBversion );
print "Upgrade to $DBversion done (Bug 19670 - Change collation of marc_field to allow mixed case search field mappings)\n";
}

14
installer/data/mysql/updatedatabase.pl

@ -17946,6 +17946,20 @@ if( CheckVersion( $DBversion ) ) {
print "Upgrade to $DBversion done (Bug 12166 - Remove 'Reserve Charge' text from accountlines description)\n";
}
$DBversion = '18.12.00.041';
if( CheckVersion( $DBversion ) ) {
my $table_sth = $dbh->prepare('SHOW CREATE TABLE `search_marc_map`');
$table_sth->execute();
my @table = $table_sth->fetchrow_array();
unless ( $table[1] =~ /`marc_field`.*COLLATE utf8mb4_bin/ ) { #catches utf8mb4 collated tables
$dbh->do("ALTER TABLE `search_marc_map` MODIFY `marc_field` VARCHAR(255) NOT NULL COLLATE utf8mb4_bin COMMENT 'the MARC specifier for this field'");
}
# Always end with this (adjust the bug info)
SetVersion( $DBversion );
print "Upgrade to $DBversion done (Bug 19670 - Change collation of marc_field to allow mixed case search field mappings)\n";
}
# SEE bug 13068
# if there is anything in the atomicupdate, read and execute it.

Loading…
Cancel
Save