diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql index 6db41e74f1..38435b9118 100644 --- a/installer/data/mysql/kohastructure.sql +++ b/installer/data/mysql/kohastructure.sql @@ -3024,7 +3024,6 @@ CREATE TABLE `aqorders` ( -- information related to the basket line items `freight` decimal(28,6) default NULL, -- shipping costs (not used) `unitprice` decimal(28,6) default NULL, -- the actual cost entered when receiving this line item `quantityreceived` smallint(6) NOT NULL default 0, -- the quantity that have been received so far - `cancelledby` varchar(10) default NULL, -- not used? always NULL `datecancellationprinted` date default NULL, -- the date the line item was deleted `order_internalnote` mediumtext, -- notes related to this order line, made for staff `order_vendornote` mediumtext, -- notes related to this order line, made for vendor diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index 57464baeed..0c2770545e 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -8867,6 +8867,16 @@ if ( CheckVersion($DBversion) ) { SetVersion($DBversion); } +$DBversion = "3.17.00.XXX"; +if ( CheckVersion($DBversion) ) { + $dbh->do(q| + ALTER TABLE aqorders DROP COLUMN cancelledby; + |); + + print "Upgrade to $DBversion done (Bug 11007 - DROP column aqorders.cancelledby)\n"; + SetVersion($DBversion); +} + =head1 FUNCTIONS =head2 TableExists($table) diff --git a/t/db_dependent/Acquisition.t b/t/db_dependent/Acquisition.t index 1570480d4c..1a559b8305 100755 --- a/t/db_dependent/Acquisition.t +++ b/t/db_dependent/Acquisition.t @@ -324,7 +324,6 @@ my @expectedfields = qw( freight unitprice quantityreceived - cancelledby datecancellationprinted supplierreference purchaseordernumber @@ -400,7 +399,6 @@ my @base_expectedfields = qw( ecost uncertainprice marc - cancelledby url isbn copyrightdate @@ -565,7 +563,6 @@ ok( datereceived orderstatus supplierreference - cancelledby isbn copyrightdate gstrate