Bug 8835 - DBRev 16.06.00.050
This commit is contained in:
parent
88b4baceee
commit
312783f8fc
2
Koha.pm
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 = "16.06.00.049";
|
||||
$VERSION = "16.06.00.050";
|
||||
|
||||
sub version {
|
||||
return $VERSION;
|
||||
|
|
|
|||
|
|
@ -1,23 +0,0 @@
|
|||
$DBversion = "16.06.00.XXX";
|
||||
if ( CheckVersion($DBversion) ) {
|
||||
|
||||
# If index issn_idx still exists, we assume that dbrev 3.15.00.049 failed,
|
||||
# and we repeat it (partially).
|
||||
# Note: the db rev only pertains to biblioitems and is not needed for
|
||||
# deletedbiblioitems.
|
||||
|
||||
my $temp = $dbh->selectall_arrayref( "SHOW INDEXES FROM biblioitems WHERE key_name = 'issn_idx'" );
|
||||
|
||||
if( @$temp > 0 ) {
|
||||
$dbh->do( "ALTER TABLE biblioitems DROP INDEX isbn" );
|
||||
$dbh->do( "ALTER TABLE biblioitems DROP INDEX issn" );
|
||||
$dbh->do( "ALTER TABLE biblioitems DROP INDEX issn_idx" );
|
||||
$dbh->do( "ALTER TABLE biblioitems CHANGE isbn isbn MEDIUMTEXT NULL DEFAULT NULL, CHANGE issn issn MEDIUMTEXT NULL DEFAULT NULL" );
|
||||
$dbh->do( "ALTER TABLE biblioitems ADD INDEX isbn ( isbn ( 255 ) ), ADD INDEX issn ( issn ( 255 ) )" );
|
||||
print "Upgrade to $DBversion done (Bug 8835). Removed issn_idx.\n";
|
||||
} else {
|
||||
print "Upgrade to $DBversion done (Bug 8835). Everything is fine.\n";
|
||||
}
|
||||
|
||||
SetVersion($DBversion);
|
||||
}
|
||||
|
|
@ -13663,6 +13663,30 @@ if( CheckVersion( $DBversion ) ) {
|
|||
print "Upgrade to $DBversion done (Bug 17391 - ReturnpathDefault and ReplyToDefault missing from syspref.sql)\n";
|
||||
}
|
||||
|
||||
$DBversion = "16.06.00.050";
|
||||
if ( CheckVersion($DBversion) ) {
|
||||
|
||||
# If index issn_idx still exists, we assume that dbrev 3.15.00.049 failed,
|
||||
# and we repeat it (partially).
|
||||
# Note: the db rev only pertains to biblioitems and is not needed for
|
||||
# deletedbiblioitems.
|
||||
|
||||
my $temp = $dbh->selectall_arrayref( "SHOW INDEXES FROM biblioitems WHERE key_name = 'issn_idx'" );
|
||||
|
||||
if( @$temp > 0 ) {
|
||||
$dbh->do( "ALTER TABLE biblioitems DROP INDEX isbn" );
|
||||
$dbh->do( "ALTER TABLE biblioitems DROP INDEX issn" );
|
||||
$dbh->do( "ALTER TABLE biblioitems DROP INDEX issn_idx" );
|
||||
$dbh->do( "ALTER TABLE biblioitems CHANGE isbn isbn MEDIUMTEXT NULL DEFAULT NULL, CHANGE issn issn MEDIUMTEXT NULL DEFAULT NULL" );
|
||||
$dbh->do( "ALTER TABLE biblioitems ADD INDEX isbn ( isbn ( 255 ) ), ADD INDEX issn ( issn ( 255 ) )" );
|
||||
print "Upgrade to $DBversion done (Bug 8835). Removed issn_idx.\n";
|
||||
} else {
|
||||
print "Upgrade to $DBversion done (Bug 8835). Everything is fine.\n";
|
||||
}
|
||||
|
||||
SetVersion($DBversion);
|
||||
}
|
||||
|
||||
# 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.
|
||||
|
|
|
|||
Loading…
Reference in New Issue