[Koha-bugs] [Bug 19016] Add a script to fix corrupted data

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Nov 22 14:47:43 CET 2017


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

Oliver Bock <oliver.bock at aei.mpg.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |oliver.bock at aei.mpg.de

--- Comment #16 from Oliver Bock <oliver.bock at aei.mpg.de> ---
FWIW, I just tried the script with all the patches (up to now) and ran into a
FK constraint violation:


% ./cleanup_database.pl --fix-corrupted-data

 * Tables biblio/deletedbiblio: 1455
Updating biblio.biblionumber=1455 with new id 1516
DBD::mysql::st execute failed: Cannot add or update a child row: a foreign key
constraint fails (`koha_koha`.`items`, CONSTRAINT `items_ibfk_5` FOREIGN KEY
(`biblionumber`) REFERENCES `biblio` (`biblionumber`) ON DELETE CASCADE ON
UPDATE CASCADE) [for Statement "UPDATE biblio SET biblionumber = ? WHERE
biblionumber = ?" with ParamValues: 0=1516, 1=1455] at ./cleanup_database.pl
line 510, <DATA> line 755.
Something went wrong, rolling back!

 * Tables biblioitems/deletedbiblioitems: 1455
Updating biblioitems.biblioitemnumber=1455 with new id 1516

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


More information about the Koha-bugs mailing list