Topic: Exchange Variance Error

Please help..!!!!
My Exchange Variance is wrong.
I have set correctly Exchange Rates, but always generate Excessive.


Journal Entry    360    30-Jun-2017             36,153,961,430,173.00        72,307,922,870,772.69    Exchange Variance
Journal Entry    361    30-Jun-2017             72,307,922,860,346.00        144,615,845,731,118.69    Exchange Variance
Journal Entry    362    30-Jun-2017             144,615,845,720,690.00        289,231,691,451,808.69    Exchange Variance
Journal Entry    365    30-Jun-2017             289,231,691,439,930.00        578,463,382,891,738.75    Exchange Variance

Re: Exchange Variance Error

You will need to provide more information. What is your home currency? What exchange currency is involved and what rate have you set?

Re: Exchange Variance Error

You probably divided instead of multiplying (or viceversa). As stated by @Dynamic, we would need to know your home currency, your rates, the foreign currency... so that we may provide some help by looking into it.

4 (edited by hakim 07/24/2017 09:32:32 am)

Re: Exchange Variance Error

My default Currency is USD, but the transaction with curency IDR.
The Exchange Rates is generate automatically is no problem.

Exchange Variance.png

Re: Exchange Variance Error

What is the exchange rate employed?

Re: Exchange Variance Error

The Exchange Rates is generate automatically.

Exchange Rates.png

Post's attachments

Exchange Rates.png 22.4 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Exchange Variance Error

The Rupiah Exchange rate would need additional decimal places if say the USD is the base currency!
If you keep your Indonesian Rupiah as the base currency all should be well.
Alternatively, you can omit the last 3 decimal places of the Indonesian Rupiah and modify the exchange rate entries accordingly.

As it is, if you want to change the decimal places size, then do it in Setup -> Display Setup (Preferences) in the Web UI.

Post's attachments

IDR_dec.png 43.4 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

8 (edited by ichtus 08/14/2017 07:55:31 am)

Re: Exchange Variance Error

Rupiah exchanges rates is generated automatically from
/*
    Choose Exchange Rate Provider
    Default is ECB for backwards compatibility
*/
$xr_providers = array("ECB", "YAHOO", "GOOGLE", "BLOOMBERG");
$dflt_xr_provider = 2;

the problem that may need to elaborate, in the different vendor and value, the exchange rates seems doubled from the last transaction, we check in the table currency, values in the some dates is wrong get from google shown 0.0001, but we have correctly this to 0.000074954090619496, even in the pages https://domain/fa/gl/manage/exchange_rates.php? this always shown 0.0001.

other trans is seems correct to automatically calc for exchange rate difference, but in this case, we still dont have any clue but some transaction will cause exchage rate difference double from the last value:
Journal Entry    360    30-Jun-2017             36,153,961,430,173.00        72,307,922,870,772.69    Exchange Variance
Journal Entry    361    30-Jun-2017             72,307,922,860,346.00        144,615,845,731,118.69    Exchange Variance
Journal Entry    362    30-Jun-2017             144,615,845,720,690.00        289,231,691,451,808.69    Exchange Variance
Journal Entry    365    30-Jun-2017             289,231,691,439,930.00        578,463,382,891,738.75    Exchange Variance

pls advice how we can solve this?

thanks

Re: Exchange Variance Error

Setup -> Display Setup - Exchange Rates -> 8

Base Currency: USD

Banking and GL -> Exchange Rates -> shows 8 decimal places.

The BuyRate form field is set to allow upto 15 digits.

Now all calculation should be okay.

Post's attachments

IDR_8_digit_xchg.png 20.8 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Exchange Variance Error

This is not happen on payment to supplier, but also other bank payments

Following example cash payment:

I enter internet bill payment of IDR 1,000,000. This equivalent to USD 74.95 (figure 1.png).
After that I check Journal Inquiry, there are new transactions that I input and also transactions that generate automatically by system with value of USD 3699,81 with description of Exchange Variance. (figure 2.png)
This is very impossible, because the transaction is only USD 74.95.

I have changed the exchange rate by 8 decimal
Exchange Rates.png)

Post's attachments

FA_screenshots.zip 39.4 kb, 1 downloads since 2017-08-23 

You don't have the permssions to download the attachments of this post.

Re: Exchange Variance Error

What is the base currency of your company?

Re: Exchange Variance Error

base currency is USD, but we operate for costing is IDR

sorry for delay, seems punbb dont email for the updates.

thanks

Re: Exchange Variance Error

The change to 8 decimal places would affect new transactions only as the computations were done for the old ones using the limited decimal places that existed earlier.

If you keep IDR as the base currency and use USD for specific needs, the standard FA settings would suffice.

@joe: Does this warrant a check? Rounding off errors cannot be that big....

Re: Exchange Variance Error

The exchange rate calculations have been the same for over 10 years.

Fot huge currency rates, it is important to use adequate decimals. Otherwise the values will vary very much.

Joe

Re: Exchange Variance Error

I have seen this is not problem with rounding error, but somehow any transaction that causes exchange variance does not calculate from the transaction value, but it seems double value from the previous exchange rates values.

We got very confused as to how we can report and diagnose this problem, except if possible we send our database dump by PM?

Re: Exchange Variance Error

Here is a tedious way of troubleshooting it.
Turn on all debug including select in sql trail in the config file.
Insert the troubleshooting code at each place in the FA scripts sequentially to inspect where the error comes in.
Sample troubleshooting code:

$log_output = "\n\n Start dump of all variables \n\n" . print_r(get_defined_vars(),true) . "\n\n";
file_put_contents('D:/XAMPP/htdocs/fa24/tmp/log_file.txt', $log_output, FILE_APPEND);

Re: Exchange Variance Error

Hi all,

Actually we have the same problem here. Our home currency is HKD (Hong Kong Dollar). Start using FA since 2014 and never had this problem before. Until this year June. We have so many Journal entry generated by system with MEMO "Exchange Variance" in the system. I checked the exchange rate are all fine. And I have no idea what should I do to solve this problem.

Any hints or help please?!!

Kevin

18 (edited by kvvaradha 10/06/2017 01:47:40 pm)

Re: Exchange Variance Error

Try to change the exchange provider and check it. 

$xr_providers = array("ECB", "YAHOO", "GOOGLE", "BLOOMBERG");
$dflt_xr_provider = 2;

change it from your config.php  .
And also enable debugging mode to see whether it throws any error during conversions.

FrontAccounting Enabling Debugging Mode

Subscription service based on FA
HRM CRM POS batch Themes

Re: Exchange Variance Error

https://frontaccounting.com/fawiki/index.php?n=Devel.TrobleshootingFrontAccounting

Re: Exchange Variance Error

I tried to enable debugging mode. After that, what I should look into it?

Journal entry

Exchange variance

Post's attachments

Journal_Xchg_var.zip 1.5 mb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Exchange Variance Error

For a start, you can make decimals 0 length for Amounts.

@joe: separating the amounts and prices into 2 separate config variables for decimal length may be needed to accommodate such cases.

Re: Exchange Variance Error

It is difficult with these huge exchange rate differences. As @apmuthu mentions, maybe a set of decimals in amounts to 0 will solve it.

I will show the discussion to Janusz.

/Joe

Re: Exchange Variance Error

Hi @Joe and @apmuthu,

I set the decimals length of Amounts in "Display setup" to 0 already. And what should I do next?
Decimal length to 0

How can I fix the "foreign exchange gain"?
Foreign exchange gain in Profit and Lost statement

Kevin Lee

Re: Exchange Variance Error

Hi @joe and @apmuthu,

Is the error message below related to this case?

Error message

Kevin Lee

Re: Exchange Variance Error

Those exchange variance postings are not any bug result, this is exactly how automatic currency accounts revaluation works.

When you make any foreign (i.e. not home) currency payment (or deposit), current money value on the related account is recalculated and the difference in value (due to changed exchange rate since recent currency operation) is posted. If you do not want this to be done automatically, you should set 'Automatic Revaluation Currency Accounts' option in your Company Setup to off.

Then you will have to make currency accounts revaluation manually when you need it, but those isolated automatic 'Exchange Variance' postings will not appear unexpectedly in your GL.

Janusz