From 35101c91279849ee2df0c4d5bc1c6529feaddf0c Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Fri, 21 Oct 2016 14:37:46 +0000 Subject: [PATCH] Bug 10455 - DBRev 16.06.00.034 Signed-off-by: Kyle M Hall --- Koha.pm | 2 +- Koha/Schema/Result/Biblioitem.pm | 11 ++--------- Koha/Schema/Result/Deletedbiblioitem.pm | 11 ++--------- installer/data/mysql/atomicupdate/bug_10455.sql | 2 -- installer/data/mysql/updatedatabase.pl | 14 ++++++++++++++ 5 files changed, 19 insertions(+), 21 deletions(-) delete mode 100644 installer/data/mysql/atomicupdate/bug_10455.sql diff --git a/Koha.pm b/Koha.pm index 8d638e00d7..0e7c99a5f9 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 = "16.06.00.033"; +$VERSION = "16.06.00.034"; sub version { return $VERSION; diff --git a/Koha/Schema/Result/Biblioitem.pm b/Koha/Schema/Result/Biblioitem.pm index a9b926ac75..a26314f6a1 100644 --- a/Koha/Schema/Result/Biblioitem.pm +++ b/Koha/Schema/Result/Biblioitem.pm @@ -157,11 +157,6 @@ __PACKAGE__->table("biblioitems"); is_nullable: 1 size: 25 -=head2 marc - - data_type: 'longblob' - is_nullable: 1 - =head2 url data_type: 'text' @@ -274,8 +269,6 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, "lccn", { data_type => "varchar", is_nullable => 1, size => 25 }, - "marc", - { data_type => "longblob", is_nullable => 1 }, "url", { data_type => "text", is_nullable => 1 }, "cn_source", @@ -341,8 +334,8 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.07039 @ 2015-02-24 14:19:57 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:A/4lKYlKWWd8TcMVzMRtCg +# Created by DBIx::Class::Schema::Loader v0.07042 @ 2016-10-21 14:37:19 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:sIIeEpbe61VNkEYpUXNDkw __PACKAGE__->belongs_to( biblio => "Koha::Schema::Result::Biblio", "biblionumber" ); diff --git a/Koha/Schema/Result/Deletedbiblioitem.pm b/Koha/Schema/Result/Deletedbiblioitem.pm index 659ced058f..ce588b73c1 100644 --- a/Koha/Schema/Result/Deletedbiblioitem.pm +++ b/Koha/Schema/Result/Deletedbiblioitem.pm @@ -156,11 +156,6 @@ __PACKAGE__->table("deletedbiblioitems"); is_nullable: 1 size: 25 -=head2 marc - - data_type: 'longblob' - is_nullable: 1 - =head2 url data_type: 'text' @@ -268,8 +263,6 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, "lccn", { data_type => "varchar", is_nullable => 1, size => 25 }, - "marc", - { data_type => "longblob", is_nullable => 1 }, "url", { data_type => "text", is_nullable => 1 }, "cn_source", @@ -303,8 +296,8 @@ __PACKAGE__->add_columns( __PACKAGE__->set_primary_key("biblioitemnumber"); -# Created by DBIx::Class::Schema::Loader v0.07039 @ 2015-02-24 14:19:57 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:RTMXhtMKvih1zhllHwwwYQ +# Created by DBIx::Class::Schema::Loader v0.07042 @ 2016-10-21 14:37:19 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Rijc/QK/Kdh3bMcbOTF8Tg # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/installer/data/mysql/atomicupdate/bug_10455.sql b/installer/data/mysql/atomicupdate/bug_10455.sql deleted file mode 100644 index 8e81536c67..0000000000 --- a/installer/data/mysql/atomicupdate/bug_10455.sql +++ /dev/null @@ -1,2 +0,0 @@ -ALTER TABLE biblioitems DROP COLUMN marc; -ALTER TABLE deletedbiblioitems DROP COLUMN marc; diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 7d67fe2aa1..179e9303c5 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -13181,6 +13181,20 @@ if ( CheckVersion($DBversion) ) { SetVersion($DBversion); } +$DBversion = "16.06.00.034"; +if ( CheckVersion($DBversion) ) { + $dbh->do(q{ + ALTER TABLE biblioitems DROP COLUMN marc; + }); + $dbh->do(q{ + ALTER TABLE deletedbiblioitems DROP COLUMN marc; + }); + + print "Upgrade to $DBversion done (Bug 10455 - remove redundant 'biblioitems.marc' field)\n"; + SetVersion($DBversion); +} + + # DEVELOPER PROCESS, search for anything to execute in the db_update directory # SEE bug 13068 -- 2.39.5