[Koha-bugs] [Bug 20271] Merge deletedbiblio* and deleteitems tables with their "alive" cousins

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Apr 4 09:18:49 CEST 2018


--- Comment #32 from Benjamin Rokseth <benjamin.rokseth at deichman.no> ---
(In reply to Ere Maijala from comment #31)
> I'm working on it now. 
> Looks like there may be a typo in the atomic update. I got the following
> error:
> updatedatabase.pl: DBD::mysql::db do failed: Can't DROP FOREIGN KEY
> `deletedbiblio_metadata_fk_1`; check that it exists [for Statement "ALTER
> TABLE deletedbiblio_metadata DROP FOREIGN KEY deletedbiblio_metadata_fk_1"]
> at (eval 1389) line 8.
> Looking at the old kohastructure.sql I believe it should have tried to drop
> 'deletedrecord_metadata_fk_1'.

hmm, sad to say, but no, it's not a typo but db design issues.
this commit seems to have added to the confusion:
(Bug 17196)

and following Bug 18284 you can see that most agree on deleted* tables being a
bad idea in the first place.

Problem is, kohastructure.sql and updatedatabase.pl is not in sync and
libraries having migrated from 16.05 and before would need to delete this
foreign key. And this patch is most important for them anyways.

I suppose we could add a delete foreign key for both and ignore errors rather
than die in the final version

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

More information about the Koha-bugs mailing list