update structure table logs

This commit is contained in:
Bernat 2018-10-29 11:35:17 +01:00
parent ba778d5d31
commit 5480c5bdbf
4 changed files with 44 additions and 0 deletions

View File

@ -0,0 +1,11 @@
DROP TRIGGER IF EXISTS `vn`.`itemLog_BEFORE_INSERT`;
DELIMITER $$
USE `vn`$$
CREATE DEFINER=`root`@`%` TRIGGER `vn`.`itemLog_BEFORE_INSERT` BEFORE INSERT ON `itemLog` FOR EACH ROW
BEGIN
IF NEW.newInstance is NULL THEN
SET NEW.newInstance = NEW.description;
END IF;
END$$
DELIMITER ;

View File

@ -0,0 +1,11 @@
DROP TRIGGER IF EXISTS `vn`.`ticketLog_BEFORE_INSERT`;
DELIMITER $$
USE `vn`$$
CREATE DEFINER=`root`@`%` TRIGGER `vn`.`ticketLog_BEFORE_INSERT` BEFORE INSERT ON `ticketLog` FOR EACH ROW
BEGIN
IF NEW.newInstance is NULL THEN
SET NEW.newInstance = NEW.description;
END IF;
END$$
DELIMITER ;

View File

@ -0,0 +1,11 @@
DROP TRIGGER IF EXISTS `vn`.`claimLog_BEFORE_INSERT`;
DELIMITER $$
USE `vn`$$
CREATE DEFINER=`root`@`%` TRIGGER `vn`.`claimLog_BEFORE_INSERT` BEFORE INSERT ON `claimLog` FOR EACH ROW
BEGIN
IF NEW.newInstance is NULL THEN
SET NEW.newInstance = NEW.description;
END IF;
END$$
DELIMITER ;

View File

@ -0,0 +1,11 @@
DROP TRIGGER IF EXISTS `vn`.`clientLog_BEFORE_INSERT`;
DELIMITER $$
USE `vn`$$
CREATE DEFINER=`root`@`%` TRIGGER `vn`.`clientLog_BEFORE_INSERT` BEFORE INSERT ON `clientLog` FOR EACH ROW
BEGIN
IF NEW.newInstance is NULL THEN
SET NEW.newInstance = NEW.description;
END IF;
END$$
DELIMITER ;