[Koha-bugs] [Bug 34520] Database update 22.06.00.078 breaks update process
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Mon Oct 30 17:12:28 CET 2023
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=34520
Nick Clemens <nick at bywatersolutions.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #158052|0 |1
is obsolete| |
--- Comment #6 from Nick Clemens <nick at bywatersolutions.com> ---
Created attachment 158080
-->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=158080&action=edit
Bug 34520: Fix FK for item_groups in reserves for new installations
There was a discrepancy between the database update for reserves
and the kohastructure.sql definition. This makes sure that the
FK is always "ON DELETE SET NULL".
To test:
* Before applying this path
* sudo koha-mysql kohadev
* show create table reserves;
CONSTRAINT `reserves_ibfk_ig` FOREIGN KEY (`item_group_id`) REFERENCES
`item_groups` (`item_group_id`) ON DELETE CASCADE ON UPDATE CASCADE
* Apply patch
* Run database update
* Check database again:
CONSTRAINT `reserves_ibfk_ig` FOREIGN KEY (`item_group_id`) REFERENCES
`item_groups` (`item_group_id`) ON DELETE SET NULL ON UPDATE CASCADE
* reset_all (create a new database)
* Check database again:
CONSTRAINT `reserves_ibfk_ig` FOREIGN KEY (`item_group_id`) REFERENCES
`item_groups` (`item_group_id`) ON DELETE SET NULL ON UPDATE CASCADE
Signed-off-by: David Nind <david at davidnind.com>
Signed-off-by: Nick Clemens <nick at bywatersolutions.com>
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list