Magento bulk price changes

后端 未结 4 812
孤城傲影
孤城傲影 2021-02-10 01:22

What I\'m trying to do is, a bulk price change on products in a certain category. We receive suggested retail prices from our vendor, but sometimes these don\'t work for us. So

4条回答
  •  暗喜
    暗喜 (楼主)
    2021-02-10 02:21

    Honestly, B00MER has the right idea, but I've also had to do similar things in a pinch before. Plus, I felt like writing a little SQL. If you just want to multiply costs by 1.2 for all products in a category, you can do something like this:

    update catalog_product_entity_decimal
      set value = value*1.2
      where attribute_id = 75 and
            entity_id IN (select product_id from catalog_category_product
                        where category_id = X);
    

    You'll doubtless need to reindex everything and check your results to make sure. Obviously, replace X with your target category, and it appears that you use a table prefix of m_, so append that too (I'm leaving it off for other searchers who come here).

    Hope that helps!

    Thanks, Joe

提交回复
热议问题