Quoting Mike Alexander <[EMAIL PROTECTED]>:
--On February 20, 2006 9:15:05 AM -0800 Andrew Sackville-West
<[EMAIL PROTECTED]> wrote:
One thing I would add to the discussion is to point out that the
pricedb is used for two things in this report (and elsewhere). It
contains prices in some currency for the commodities (stocks, bonds,
etc.) that are being reported on and it also contains exchange rates
used for converting amounts from one currency to another. The
report can infer the first of these from the transactions, but not
the latter. It really needs the pricedb for that.
Yeah, that's definitely a problem. There needs to bhe another
exchange-fn, one that doesn't rely on pricedb. And we probably need to
create BOTH of them in the report simultaneously because we can't know
which "type" of price data we're going to get in advance. 1) for when
the pricedb is our source and 2) for when the txn is the source. The
question is, how can we get currency exchange data? Can we rely on
there being exchange data if someone is working in multiple
currencies?
I think you have to rely on that. I can't think of any other way to
get the exchange rates, unless a whole new way of storing them is
invented outside the pricedb. Generally there aren't enough
multiple-currency transactions to be useful and they would be hard to
find.
Personally, I'm less worried about translating across currencies than I
am about getting a proper stock->currency price. Let's get the report
working "correctly" for a single currency, and then we can add in support
for multiple currencies.
Granted, I'm not 100% sure how to report multiple currencies, whether to
report it all based on the current exchange rate, or whether to report it
based on the exchange rate closest in time to the actual transactions.
Mike
-derek
--
Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
Member, MIT Student Information Processing Board (SIPB)
URL: http://web.mit.edu/warlord/ PP-ASEL-IA N1NWH
[EMAIL PROTECTED] PGP key available
_______________________________________________
gnucash-devel mailing list
[email protected]
https://lists.gnucash.org/mailman/listinfo/gnucash-devel