Bug 30497: Recreate old_reserves_ibfk_4 when it cascades
authorMarcel de Rooy <m.de.rooy@rijksmuseum.nl>
Fri, 8 Apr 2022 08:23:56 +0000 (08:23 +0000)
committerTomas Cohen Arazi <tomascohen@theke.io>
Thu, 22 Sep 2022 11:33:58 +0000 (08:33 -0300)
commit14b9274135f32c92c655fc070eb912c4f39b4eca
tree7a6c41ba9538653762dad936172d1b2a88c907a0
parent4a27800c62a5494284b066405d0543bc7689f7e9
Bug 30497: Recreate old_reserves_ibfk_4 when it cascades

Test plan:
Drop old_reserves_ibfk_4.
Add back with:
    alter table old_reserves ADD CONSTRAINT `old_reserves_ibfk_4` FOREIGN KEY (`itemtype`) REFERENCES `itemtypes` (`itemtype`) ON DELETE CASCADE ON UPDATE CASCADE;
Run dbrev. Check that constraint has been replaced by SET NULL.
Run dbrev again. No changes.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
[EDIT 23-08-22 Replaced DROP CONSTRAINT]

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
installer/data/mysql/atomicupdate/bug_30497.pl [new file with mode: 0755]