mysql insert trigger
DELIMITER //
CREATE TRIGGER contacts_after_insert
AFTER INSERT
ON contacts FOR EACH ROW
BEGIN
-- Insert record into audit table
INSERT INTO contacts_audit
( contact_id,
created_date,
created_by)
VALUES
( NEW.contact_id,
SYSDATE(),
"Admin" );
END; //
DELIMITER ;