feat: refs #8069 new trigger hedera.orderRow_afterInsert

This commit is contained in:
Pako Natek 2024-10-01 14:25:10 +02:00
parent 304992e7cf
commit fd262e32c1
2 changed files with 13 additions and 0 deletions

View File

@ -0,0 +1,10 @@
DELIMITER $$
CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `hedera`.`orderRow_afterInsert`
AFTER INSERT ON `orderRow`
FOR EACH ROW
BEGIN
UPDATE `order`
SET rowUpdated = NOW()
WHERE id = NEW.orderFk;
END$$
DELIMITER ;

View File

@ -0,0 +1,3 @@
-- Place your SQL code here
ALTER TABLE hedera.`order` ADD IF NOT EXISTS rowUpdated DATETIME NULL
COMMENT 'Timestamp for last updated record in orderRow table';