11 lines
312 B
MySQL
11 lines
312 B
MySQL
|
DELIMITER $$
|
||
|
CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`operator_beforeUpdate`
|
||
|
BEFORE UPDATE ON `operator`
|
||
|
FOR EACH ROW
|
||
|
BEGIN
|
||
|
IF NOT (NEW.labelerFk <=> OLD.labelerFk AND NEW.sectorFk <=> OLD.sectorFk) THEN
|
||
|
CALL vn.printer_checkSector(NEW.labelerFk, NEW.sectorFk);
|
||
|
END IF;
|
||
|
END$$
|
||
|
DELIMITER ;
|