[Koha] Duplicate entry in old_reserves

Tim McMahon tmcmahon at wlpl.org
Wed Feb 1 06:16:50 NZDT 2017


I got an internal server error while checking out a reserved item to a 
patron.

The plack-error.log showed this error:

DBD::mysql::st execute failed: Duplicate entry '4515' for key 'PRIMARY' 
[for Statement "INSERT INTO `old_reserves` ( `biblionumber`, 
`borrowernumber`, `branchcode`, `cancellationdate`, `expirationdate`, 
`found`, `itemnumber`, `itemtype`, `lowestPriority`, `notificationdate`, 
`priority`, `reminderdate`, `reserve_id`, `reservedate`, `reservenotes`, 
`suspend`, `suspend_until`, `timestamp`, `waitingdate`) VALUES ( ?, ?, 
?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )" with ParamValues: 
0='4095', 1='4310', 2='WLPL', 3=undef, 4=undef, 5='F', 6='4177', 
7=undef, 8='0', 9=undef, 10=0, 11=undef, 12='4515', 13='2017-01-26', 
14='', 15='0', 16=undef, 17='2017-01-26 14:05:25', 18='2017-01-26'] at 
/usr/share/perl5/DBIx/Class/Storage/DBI.pm line 1832.
DBIx::Class::Storage::DBI::_dbh_execute(): Duplicate entry '4515' for 
key 'PRIMARY' at /usr/share/koha/lib/Koha/Object.pm line 120

I checked in the old_reserves table and found that there was already an 
entry with a reserve_id of 4515.

Does anyone know how this would happen?

I'm running Koha 16.11.20.000 on Debian 8 and just updated from packages 
last Wednesday if that's any help.

-- 
Tim McMahon
Technical Services
West Liberty Public Library


More information about the Koha mailing list