search

Home  >  Q&A  >  body text

mysql trigger error

DROP TRIGGER IF EXISTS chufa;CREATE DEFINER=root@localhost TRIGGER chufa AFTER INSERT ON db_product FOR EACH ROW INSERT INTO db_change (value, theme) VALUES (concat('/path/',product_id),theme_value)

When a new record is generated in db_product, merge the string /path/ with the product_id in the db_product table, and insert it together with theme_value into the value and theme fields of db_change

I don’t know what the error is, but it doesn’t work. consult

大家讲道理大家讲道理2806 days ago608

reply all(1)I'll reply

  • 滿天的星座

    滿天的星座2017-05-18 10:49:14

    Tell me where theme_value comes from, and the syntax of new or old before product_id is not written

    reply
    0
  • Cancelreply