When the user enters an exchange rate, it's not saved directly. Instead, the
relation between the original amount and the converted amount is stored. As a
consequence, the exchange rate precision will depend on the precision of the
two currencies.
In addition, the converted amount is (wrongly) stored with the currency of the
original amount and rounded to its decimal places. If the original amount has
no decimal places, even more precision is lost.
For example, if the user transfers from a Yens account (no decimal places) to an
Euros account (2 decimal places) and enters:
- transaction amount = 10 (Yens, no decimal places)
- exchange rate = 0.123456
GnuCash calculates:
- converted transaction amount: 1 (1.23456 rounded to 0 decimals)
- exchange rate (stored in DB): 1/10 = 0.1
GnuCash should store directly the exchange rate instead of calculating it.
When the user enters an exchange rate, it's not saved directly. Instead, the
relation between the original amount and the converted amount is stored. As a
consequence, the exchange rate precision will depend on the precision of the
two currencies.
In addition, the converted amount is (wrongly) stored with the currency of the
original amount and rounded to its decimal places. If the original amount has
no decimal places, even more precision is lost.
For example, if the user transfers from a Yens account (no decimal places) to an
Euros account (2 decimal places) and enters:
GnuCash calculates:
GnuCash should store directly the exchange rate instead of calculating it.