我正在尝试在 phpMyAdmin 中创建一个触发器,我可以在其中根据字段名称在插入字段时修改字段的值。我正在使用这种语法
CREATE TRIGGER lawyers AFTER INSERT ON wp_posts
FOR EACH ROW
BEGIN
UPDATE wp_posts SET post_content = '<!--:en--> <!--:--><!--:ES--> <!--:-->'
WHERE ID = NEW.ID AND post_type = 'lawyers';
END
但我不能让它工作,它说:
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 4
你能帮我么?