Zen Cart Logo
Forums / Currencies & Sales Taxes, VAT, GST, etc. / How to change all prices to different currency?

How to change all prices to different currency?

Locked

Views: 3,246

Results 1 to 8 of 8
This thread is locked. New replies are disabled.
8 Feb 2009, 12:54 PM
#1
davidvitazka avatar

davidvitazka

New Zenner

Join Date:
Jul 2008
Posts:
16
Plugin Contributions:
0

How to change all prices to different currency?

Hi,
I have to change all the prices in my eshop to different currency. Is there some easy way how to change all at once or do I have to do change price on every product in administration?

Thanks, I really need it!

8 Feb 2009, 1:01 PM
#2
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: How to change all prices to different currency?

The quickest way is to run and sql patch on the WHOLE database.

YOU MUST BACKUP YOUR DATABASE FIRST

Go to Tools >> Install SQL Patches

Then run the following:

update products set products_price = products_prie * '1.5';

Obviously use your own conversion rate, where here I've used a rate of 1.5.

Next, just set the default currency to be which ever currency you have chosen to use.

**Please note: **This is a general how-to and is given as a hint, not a complete solution. I only say this because I don't know your exact circumstances. Please ensure you realise the consequences of using this solution before you run the patch.

Absolute

8 Feb 2009, 1:46 PM
#3
davidvitazka avatar

davidvitazka

New Zenner

Join Date:
Jul 2008
Posts:
16
Plugin Contributions:
0

Re: How to change all prices to different currency?

Absolute:

The quickest way is to run and sql patch on the WHOLE database.

YOU MUST BACKUP YOUR DATABASE FIRST

Go to Tools >> Install SQL Patches

Then run the following:

update products set products_price = products_prie * '1.5';

> Obviously use your own conversion rate, where here I've used a rate of 1.5.
> 
> Next, just set the default currency to be which ever currency you have chosen to use.
> 
> **Please note: **This is a general how-to and is given as a hint, not a complete solution.  I only say this because I don't know your exact circumstances.  Please ensure you realise the consequences of using this solution before you run the patch.
> 
> Absolute

Ok, so just to be sure. If all my porducts are in skk and one skk is 30.126 € than I will have to run

update products set products_price = products_prie * '0.03319393';


Is that all right? And also, is 1.7 MB adequate size of whole database backup?
8 Feb 2009, 1:57 PM
#4
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: How to change all prices to different currency?

If you're converting from Euro to SKK, then that is fine. If you are converting from SKK to Euro, then you want to convert the other way.

update products set products_price = products_prie * '30.126';

This means if you had a product for 1SKK, then it would be on the site for 30.13€.

Absolute

8 Feb 2009, 2:09 PM
#5
davidvitazka avatar

davidvitazka

New Zenner

Join Date:
Jul 2008
Posts:
16
Plugin Contributions:
0

Re: How to change all prices to different currency?

Absolute:

If you're converting from Euro to SKK, then that is fine. If you are converting from SKK to Euro, then you want to convert the other way.

update products set products_price = products_prie * '30.126';

> 
> This means if you had a product for 1SKK, then it would be on the site for 30.13€.
> 
> Absolute

Oh, sorry. I wrote it wrong. One Euro is 30.126 SKK! 

And how about size of my backup? Is it ok?
8 Feb 2009, 2:33 PM
#6
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: How to change all prices to different currency?

Database backup size could be right. Depends on how you are exporting, and the type of SQL statements you are using.

The SQL looks fine if that is the corrected exchange rate.

Absolute

8 Feb 2009, 2:53 PM
#7
davidvitazka avatar

davidvitazka

New Zenner

Join Date:
Jul 2008
Posts:
16
Plugin Contributions:
0

Re: How to change all prices to different currency?

Absolute:

Database backup size could be right. Depends on how you are exporting, and the type of SQL statements you are using.

The SQL looks fine if that is the corrected exchange rate.

Absolute

Ok, I put it there and I got just this.

1054 Neznáme pole /unknown field/ 'products_prie' v 'field list'
in:
[UPDATE zen_products set products_price = products_prie * '0.03319393';]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

8 Feb 2009, 3:26 PM
#8
davidvitazka avatar

davidvitazka

New Zenner

Join Date:
Jul 2008
Posts:
16
Plugin Contributions:
0

Re: How to change all prices to different currency?

Ah, looks like only problem was that you left "c" in price. Now it works! Realy thank you, this is awesome. I was trying to do that for long time and this is very easy! :clap: