CREATE OR REPLACE TRIGGER trigger_name
AFTER UPDATE OF column ON table1
FOR EACH ROW
WHEN (NEW.column=some_value)
BEGIN
UPDATE table2 statement1 WHERE condition;
UPDATE table2 statement2 WHERE condition;
END trigger_name;
hey guys need some help on this one, need a trigger to update a row on table2 whenever a column in a row in table1 gets updated, my problem is the trigger updates all the rows in table2 for statement1 and then updates the valid row(WHEN (NEW.column=some_value)) for statement1 and statement2 , could you guys check out my case, condition used for both UPDATE statements are the same, thanks a lot guys
AFTER UPDATE OF column ON table1
FOR EACH ROW
WHEN (NEW.column=some_value)
BEGIN
UPDATE table2 statement1 WHERE condition;
UPDATE table2 statement2 WHERE condition;
END trigger_name;
hey guys need some help on this one, need a trigger to update a row on table2 whenever a column in a row in table1 gets updated, my problem is the trigger updates all the rows in table2 for statement1 and then updates the valid row(WHEN (NEW.column=some_value)) for statement1 and statement2 , could you guys check out my case, condition used for both UPDATE statements are the same, thanks a lot guys