Turiddu8686 Posted December 22, 2022 Share Posted December 22, 2022 (edited) i need copy the wholesale price in product master to wholesale price on all combinations sameone have an idea ? Edited December 22, 2022 by Turiddu8686 (see edit history) Link to comment Share on other sites More sharing options...
PrestaServicePro Posted December 22, 2022 Share Posted December 22, 2022 Hello, You can do this by creating query: UPDATE ps_product_attribute INNER JOIN ps_product_shop ON ps_product_shop.id_product = ps_product_attribute.id_product SET ps_product_attribute.wholesale_price = ps_product_shop.wholesale_price; UPDATE ps_product_attribute_shop INNER JOIN ps_product_shop ON ps_product_shop.id_product = ps_product_attribute.id_product SET ps_product_attribute.wholesale_price = ps_product_shop.wholesale_price; Note: before run query take backup of ps_product_attribute table, ps_product_attribute_shop table 1 Link to comment Share on other sites More sharing options...
Turiddu8686 Posted December 22, 2022 Author Share Posted December 22, 2022 thanks but recieve an error #1054 - unknown column 'ps_product_attribute.wholesale_price' in 'field list' Link to comment Share on other sites More sharing options...
PrestaServicePro Posted December 22, 2022 Share Posted December 22, 2022 " ps_ " add your table prefix and try again. 1 Link to comment Share on other sites More sharing options...
Turiddu8686 Posted December 22, 2022 Author Share Posted December 22, 2022 Just now, PrestaServicePro said: " ps_ " add your table prefix and try again. the table prefix is ps_ standard prestashop prefix after run your query the wholesale_price on table ps_product_attribute is valorized with cost but the table ps_product_attribute_shop, NO Link to comment Share on other sites More sharing options...
PrestaServicePro Posted December 22, 2022 Share Posted December 22, 2022 what version of PS you use? 1 Link to comment Share on other sites More sharing options...
Turiddu8686 Posted December 22, 2022 Author Share Posted December 22, 2022 Just now, PrestaServicePro said: what version of PS you use? 1.7.8.1 Link to comment Share on other sites More sharing options...
PrestaServicePro Posted December 22, 2022 Share Posted December 22, 2022 can you go to BO and check the combinations whosale_prices updated or not? 1 Link to comment Share on other sites More sharing options...
Turiddu8686 Posted December 22, 2022 Author Share Posted December 22, 2022 7 minutes ago, PrestaServicePro said: can you go to BO and check the combinations whosale_prices updated or not? no in BO not update if the attribute.shop table is not equal on BO it is not seen the problem it seems to be here UPDATE ps_product_attribute_shop INNER JOIN ps_product_shop ON ps_product_shop.id_product = ps_product_attribute.id_product SET ps_product_attribute.wholesale_price = ps_product_shop.wholesale_price; Link to comment Share on other sites More sharing options...
PrestaServicePro Posted December 22, 2022 Share Posted December 22, 2022 Hmm. replace with this one: UPDATE ps_product_attribute_shop INNER JOIN ps_product_shop ON ps_product_shop.id_product = ps_product_attribute_shop.id_product SET ps_product_attribute_shop.wholesale_price = ps_product_shop.wholesale_price; 1 Link to comment Share on other sites More sharing options...
Turiddu8686 Posted December 22, 2022 Author Share Posted December 22, 2022 thanks you are the best! work fine saved me dozens of hours of work 1 Link to comment Share on other sites More sharing options...
PrestaServicePro Posted December 22, 2022 Share Posted December 22, 2022 Glad it worked! Please edit your first post and add [SOLVED] in front of the title so other people with the same issue might find easier the solution If you find my answer helpful just click the ❤️ above and show some love.😊 Wish you the best sales! 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now