I have an old Magento ecommerce site, with about 400 products. Initially, it was made to be in EURO, both in the backend, and the frontend. I need to fully migrate it to the local currency. Here is what I've done for now: I set the BASE currency to EUR (as it was), and the display currency to RON (Romanian Leu, local currency). And I set a base exchange rate, and then set it to update daily from WebserviceX. This solved half of my problem. When a user enters, he is presented the site in the local currency, with the option to switch to EUR in topbar. But my problem is that when I add new products, is asks me in EUR. I somehow need to set the BASE currency as the local RON. But if I set it to RON, the prices do not update! — A product that is 500EUR, when base is set to eur and display to ron, displays as 2300RON, which is correct. When both the base and the display are in RON, a 500EUR product displays as 500RON, the conversion does not work if I set RON as base. I need to convert the prices in back-end automatically from EUR -> , so that than I can set base to RON and have them entered by default in RON from now on. How can I do that? I can't manually update 400 products.
Change Magento Base and Display Currency and Auto-Update Prices (EUR to RON)
currencycurrency-ratesmulticurrency
Best Answer
Here is something that should convert the prices.
I know it's not the best way of doing it by touching the db directly, but it's fast and it works.
Please back-up your db before trying any of this.
So all price related values are kept in the table
catalog_product_entity_decimal
andcatalog_product_entity_tier_price
in case you have tier prices.For tier prices is simple.
Just update the value of the column
value
with the converted value.So today the conversion rate for 1E is 4.4193 RON.
Run this query:
This should solve it.
For the rest of the prices is not that easy.
First you need to identify the attribute ids for
price
andspecial_price
.For that run this query.
This should produce 2 rows. Take the column
attribute_id
values and use them in the query below. For me these values were75
and76
.Now run this query for updating the prices.
Again
4.4193
is the exchange rate.Now you can set your base currency to RON. Clear the cache and reindex everything.