You are viewing this forum as a guest. Login to an existing account, or create a new account, to reply to topics and to create new topics.
I need to write a script for Cron to update currency conversion rates automatically, daily. But I don't know which table stores the currency conversion fields. Anyone know which one it is? Else i am faced with 1 by 1 search... thanks in advance,
James
Offline
Thanks, but its only a small time investment for me to setup the program in perl or objective-c.
Offline
The table is core_settings. Set the 'value' for the following 'id's:
core.currconv.AUD
core.currconv.CAD
core.currconv.CHF
core.currconv.EUR
core.currconv.GBP
core.currconv.JPY
core.currconv.USD
Assuming your base currency for your system is USD, make sure that one is set to '1.0000' and all others are multiples based on the USD conversion value.
Offline
got it. Thanks! Also, I wanted to add other currencies. I tried the steps for doing this in the CCP7 notes, but it failed (i am in CCP8) . I was using the raw sql entry feature. any ideas? i cut and paste...
the entry was
INSERT INTO core_settings VALUES('core.currcdp.PHP', 'Philippine Pesos (PHP): Decimal Character', 'core', 'Currency Settings: Conversions and Symbols', 'TEXTBOX-REG', '', '1', '.', 'Enter the decimal character for the Philippine Pesos (PHP) currency. This character is used in amounts shown in the Australian Dollars (PHP) currency.')
and the error was
A problem was encountered while executing the SQL statement submitted. The error was reported as: The MySQL extension encountered a problem submitting an SQL statement. MySQL reported the error as: Column count doesn't match value count at row 1
looks to me like a value is missing. fields and values add up to 9 instead of ten. as far as i can tell...
any help much appreciated.
James
Offline
Use this SQL:
INSERT INTO core_settings VALUES('core.currcdp.PHP', 'Philippine Pesos (PHP): Decimal Character', 'core', 'Currency Settings: Conversions and Symbols', 'TEXTBOX-REG', '', '', '1', '.', 'Enter the decimal character for the Philippine Pesos (PHP) currency. This character is used in amounts shown in the Australian Dollars (PHP) currency.')
We added a 'displayinclude' column in CCP8 which is right before the 'required' column.
Offline
worked perfectly. thanks! i made the fix to the other 3 Inserts too. Now i can manage the new currency via the backend and the new currency is in the drop down list...
These work in CCP 8
#1
INSERT INTO core_settings VALUES('core.currcdp.PHP', 'Philippine Pesos (PHP): Decimal Character', 'core', 'Currency Settings: Conversions and Symbols', 'TEXTBOX-REG', '', '', '1', '.', 'Enter the decimal character for the Philippine Pesos (PHP) currency. This character is used in amounts shown in the Australian Dollars (PHP) currency.')
#2
INSERT INTO core_settings VALUES('core.currconv.PHP', 'Philippine Pesos (PHP): Conversion Rate', 'core', 'Currency Settings: Conversions and Symbols', 'TEXTBOX-REG', '', '','1', '1.000', 'Enter the conversion rate for the Philippine Pesos (PHP) currency. This rate is used with amounts stored in the Base Currency to arrive at an amount for this currency to display to customers. Calculation: (Base x Rate = Display)')
#3
INSERT INTO core_settings VALUES('core.currcth.PHP', 'Philippine Pesos (PHP): Thousands Character', 'core', 'Currency Settings: Conversions and Symbols', 'TEXTBOX-REG', '', '', '1', '.', 'Enter the thousands character for the Philippine Pesos (PHP) currency. This character is used in amounts shown in the Philippine Pesos (PHP) currency.')
#4
INSERT INTO core_settings VALUES('core.currsym.PHP', 'Philippine Pesos (PHP): Currency Symbol', 'core', 'Currency Settings: Conversions and Symbols', 'TEXTBOX-REG', '', '', '1', 'PHP', 'Enter the currency symbol for the Philippine Pesos (PHP) currency. This symbol is appended to amounts shown in the Philippine Pesos (PHP) currency.')
#5
INSERT INTO core_selectcustom VALUES('core.currency.PHP','core','core.currency','Philippine Pesos','PHP','1')
Offline
My Currency symbol is not displaying properly on my website. I input ₦ as the symbol for Nigerian Naira but is is displaying ₦ on my website. What do I do?
Offline