salix/db/routines/vn/triggers/itemShelving_beforeDelete.sql

16 lines
402 B
MySQL
Raw Normal View History

DELIMITER $$
2024-01-25 16:33:54 +00:00
CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`itemShelving_beforeDelete`
BEFORE DELETE ON `itemShelving`
FOR EACH ROW
INSERT INTO vn.itemShelvingLog(itemShelvingFk,
workerFk,
accion,
shelvingFk,
itemFk)
VALUES( OLD.id,
account.myUser_getId(),
'ELIMINADO',
OLD.shelvingFk,
OLD.itemFk)$$
DELIMITER ;