DELIMITER $$ CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`itemShelvingSale_AFTER_INSERT` AFTER INSERT ON `itemShelvingSale` FOR EACH ROW BEGIN UPDATE vn.sale SET isPicked = TRUE WHERE id = NEW.saleFk; END$$ DELIMITER ;