[Koha-bugs] [Bug 30539] Koha upgrade error "Column 'claimed_on' cannot be null"

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Thu Apr 14 09:18:33 CEST 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30539

--- Comment #1 from Saiful Amin <saiful at semanticconsulting.com> ---
There is a possible bug in:
/usr/share/koha/intranet/cgi-bin/installer/data/mysql/updatedatabase.pl
(OR [master]/installer/data/mysql/updatedatabase.pl)

While checking the code I observed that the orders object has three values and
'claimed_on' is not one of them:

22053   my $orders = $dbh->selectall_arrayref(q|
22054       SELECT ordernumber, claims_count, claimed_date
22055       FROM aqorders


So, the possible patch is making following change in the line 22065 of the
updatedatabase.pl:

22063   for my $order ( @$orders ) {
22064       for my $claim (1..$order->{claims_count}) {
-22065           $insert_claim_sth->execute($order->{ordernumber},
$order->{claimed_on});
+22065           $insert_claim_sth->execute($order->{ordernumber},
$order->{claimed_date});
22066       }
22067   }

The above change fixed the upgrade process for us.

-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.


More information about the Koha-bugs mailing list