drop trigger if exists item_after_insert; DELIMITER // create trigger item_after_insert after insert on dbr_item for each row begin replace into dbr_item_thm ( id, created_on, upload_batch ) value (new.id, unix_timestamp(), new.upload_batch ) ; replace into pro_item_revsum (id, created_on, updated_on ) value (new.id, unix_timestamp(), unix_timestamp()) ; end // DELIMITER ;