From f31598ff9943cd9a2715e9fc9e14cac4b6ff1121 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Sat, 15 Sep 2018 21:44:05 +0000 Subject: [PATCH] Bug 21288: DBRev 18.05.03.002 Signed-off-by: Nick Clemens (cherry picked from commit 11e513f83f0c5fdd0d47de14b7c09635faf58ae4) Signed-off-by: Martin Renvoize (cherry picked from commit 44ce16d0069fdff7b487753277c11d368a083ccb) Signed-off-by: Fridolin Somers --- Koha.pm | 2 +- installer/data/mysql/atomicupdate/bug_21288.perl | 9 --------- installer/data/mysql/updatedatabase.pl | 11 +++++++++++ 3 files changed, 12 insertions(+), 10 deletions(-) delete mode 100644 installer/data/mysql/atomicupdate/bug_21288.perl diff --git a/Koha.pm b/Koha.pm index 96f6f358ce..e4d20b4e69 100644 --- a/Koha.pm +++ b/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 = "17.11.09.002"; +$VERSION = "18.05.03.002"; sub version { return $VERSION; diff --git a/installer/data/mysql/atomicupdate/bug_21288.perl b/installer/data/mysql/atomicupdate/bug_21288.perl deleted file mode 100644 index a4a102a64e..0000000000 --- a/installer/data/mysql/atomicupdate/bug_21288.perl +++ /dev/null @@ -1,9 +0,0 @@ -$DBversion = 'XXX'; # will be replaced by the RM -if( CheckVersion( $DBversion ) ) { - $dbh->do(q{ - CREATE INDEX `by_biblionumber` ON `subscription` (`biblionumber`) - }); - - SetVersion( $DBversion ); - print "Upgrade to $DBversion done (Bug 21288: Slowness in acquisition caused by GetInvoices\n"; -} diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 5e71bdc4fb..45673d06a3 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -15188,6 +15188,17 @@ if( CheckVersion( $DBversion ) ) { print "Upgrade to $DBversion done (Bug 21144: Add ROADTYPE to default authorised values categories)\n"; } +$DBversion = '18.05.03.002'; +if( CheckVersion( $DBversion ) ) { + unless ( index_exists( 'subscription', 'by_biblionumber' ) ) { + $dbh->do(q{ + CREATE INDEX `by_biblionumber` ON `subscription` (`biblionumber`) + }); + } + SetVersion( $DBversion ); + print "Upgrade to $DBversion done (Bug 21288: Slowness in acquisition caused by GetInvoices\n"; +} + # DEVELOPER PROCESS, search for anything to execute in the db_update directory # SEE bug 13068 # if there is anything in the atomicupdate, read and execute it. -- 2.39.5