0 użytkowników i 3 Gości przegląda ten wątek.
UPDATE ps_supplier SET active =1 WHERE id_supplier IN ((SELECT DISTINCT p.id_supplierFROM ps_supplier s, ps_product pWHERE s.id_supplier = p.id_supplier));
#1093 - You can't specify target table 'ps_supplier' for update in FROM clause
UPDATE ps_supplier SET active = 1 WHERE id_supplier IN (SELECT DISTINCT id_supplier FROM ps_product)