I have following stored procedure
DELIMITER //
CREATE TRIGGER OrderDetail_AFTER_INSERT AFTER INSERT ON OrderDetail
FOR EACH ROW
BEGIN
UPDATE Order SET total = total + NEW.subtotal WHERE id = NEW.orderid;
END;
//
DELIMITER ;
the error I am getting is
ERROR 1064 <4200>: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version fir the right syntax to use ner 'Order SET total = total + NEW.subtotal WHERE id = NEW.orderid; END' at line 5
any idea? Please help