Pavel Mišík

1

votes
2

answer
49

views

Command FOR EACH ROW in mysql

Help me please.I want to create trigger in mysql server but server wrote me SQL query: Documentation CREATE TRIGGER `dis_out_of_stock` AFTER UPDATE ON `ps_stock_available` FOR EACH ROW begin UPDATE `ps_product_shop` SET active=0 WHERE id_product IN (SELECT id_product FROM `ps_stock_available` WHE...
Pavel Mišík
1

votes
2

answer
0

views

Insert text and data into one column via command UPDATE

I have two tables: ps_product_shop and ps_product. I want update a column in ps_product_shop with this command: UPDATE `ps_product_shop` SET dm_heureka_product_sk = 'Text' AND (SELECT reference from ps_product where id_product = 508) where id_product = 508 I get this error: #1292 - Truncated incor...
Pavel Mišík