how to set Gnucash commodities (exchange rates) from Python?

Felix Schwarz felix.schwarz at oss.schwarz.eu
Mon Jan 5 17:46:48 EST 2015


Am 03.01.2015 um 17:06 schrieb John Ralls:
> There is no API for setting price/exchange rate in a split because it's not
> a stored parameter, it's the ratio between the split's "amount" expressed
> in the split's account's commodity/currency and the split's "value"
> expressed in the transaction's currency/commodity.
> 
> That's separate from the price database, which isn't used for transactions
> except that the last entered price is provided as the default value.

That makes a lot of sense and is actually exactly what I was hoping for.
Somehow this elegant solution (no "exchange rate"/calculation in actual
transactions) didn't occur to me.

Again gnucash seems to be ready to meet my needs (after dealing with my
multi-currency transactions via the GUI) so I guess as long as you keep the
Python API working I'll be a happy gnucash (API) user. :-)

Thank you very much,
fs


More information about the gnucash-user mailing list