I'm new to triggers and cannot get this to work?
- I need to log the old & new value of "omstatusID" only when it changes
- The audit values need stored in tblAudit
- Below is working SQL but not sure how to adapt it to work with HeidiSQL as a trigger?
INSERT INTO tblaudit(old_data, new_data, tbl_name) VALUES (OLD.omstatusID, NEW.omstatusID, "tblcom")