in Magento, Web Development

Magento price not saving multi scope/store

Just ran into this issue on a multi store view website in the admin backend, it seems because the product price scope is global unless you have a module to override this functionality the price should only have one attribute value, and each time you save the product in any store view you are essentially saving one price to store 0 the admin store.

If you used an importer or some other process to import your products you may find that there are incorrectly two records in the catalog_product_entity_decimal table

entity_tbl

You can look at the data via this query, replacing ATTRIBUTE_ID with your product ID

SELECT * FROM catalog_product_entity_decimal WHERE attribute_id = ATTRIBUTE_ID

How to fix?

In my store the price attribute is 75 it may differ though, there should only be one entry for store_id 0. If you now delete that row you will be able to save the product price. You can delete all these values in one line. (please backup your database first.)

DELETE FROM magento_db.catalog_product_entity_decimal WHERE attribute_id = 75 AND store_id = 2

Where store_id is the additional store entry and magento_db is your database name.

Write a Comment

Comment

  1. Hi Joel.

    I just wanted to personally thank you for posting this. I’ve spent days tearing out my hair unable to update store view prices. I’ve never come across this before – it’s a very odd bug(?)

    Your fix totally worked.

    You absolute LEGEND.

    Alex

    • Thanks Alex I know all too well what it’s like, it is indeed weird I have used Magmi importer so can only think it’s related to an import through there where the store id has been set incorrectly or assumed to the secondary store if not given.

  2. Thankyou so much for this! I have spent too much time trying to work out how to fix this issue with no luck!

    Life saver!

    Nick

  3. Thank you for your great post!
    I am having a trouble with setting up prices for each store view
    Because Magento default only allows setting up different prices at the level of website, not store views, so I am looking for a way to help me set up various prices of a product in each store view.
    I search on Google and find an extension that can solve this issue. It is called Multiple Store View Pricing
    This is its link: http://bsscommerce.com/magento-multistore-pricing.html
    But is there any programmatical way to do it beside using an extension?