hotFix delete unique refs #6281
gitea/salix/pipeline/pr-master This commit looks good Details

This commit is contained in:
Sergio De la torre 2024-06-18 17:00:15 +02:00
parent 2b1de271a9
commit ae01fb6440
1 changed files with 14 additions and 0 deletions

View File

@ -0,0 +1,14 @@
-- Place your SQL code here
USE vn;
ALTER TABLE vn.itemShelving DROP FOREIGN KEY itemShelvingBuy_FK;
ALTER TABLE vn.itemShelving DROP FOREIGN KEY itemShelving_fk2;
ALTER TABLE vn.itemShelving DROP INDEX itemShelving_UN;
ALTER TABLE vn.itemShelving ADD CONSTRAINT itemShelving_fk2 FOREIGN KEY (shelvingFk) REFERENCES vn.shelving(code) ON DELETE CASCADE ON UPDATE CASCADE;
ALTER TABLE vn.itemShelving ADD CONSTRAINT itemShelvingBuy_FK FOREIGN KEY (buyFk) REFERENCES vn.buy(id) ON DELETE RESTRICT ON UPDATE RESTRICT;