CREATE TRIGGER `client_tracker`.add_inv AFTER INSERT
ON brite_supplement
FOR EACH ROW
INSERT INTO investments ( client_id, investment_name, investment_date, investment_type, investment_amount )
SELECT brite_supplement.client_id, "27" AS Expr1, brite_supplement.investment_date, brite_supplement.investment_type, brite_supplement.investment_amount
FROM brite_supplement
WHERE brite_supplement.ID=last_insert_id();
|