custom separate trading accounts

gnucash.133518b at telus.net gnucash.133518b at telus.net
Sun May 25 20:15:32 EDT 2014


On 2014-05-25 4:28 PM, Mike Alexander wrote:
> --On May 25, 2014 12:14:03 AM -0700 gnucash.133518b at telus.net wrote:
>> I would define "wrong" to be any Advanced Portfolio report in which
>> the displayed Value does not equal the displayed number of Shares
>> multiplied by the displayed Price. That is precisely what I am seeing
>> (1000 <> 100 * 11).
>
> Oh right, *that* problem.  I had forgotten about it in the confusion.
>
> You have prices for midnight on January 4 and midnight on January 5. The
> report date, for the purpose of price lookup, is noon on January 5,
> exactly half way between these two.  The report used one function to
> look up the price and a different one to do the exchange calculation
> from SHA to CAD.  These two functions had different rules for resolving
> the halfway between situation.
>
> I've checked in a version that resolves this by always using the price
> returned from the price lookup.  You can get the new version at
> <https://raw2.github.com/Gnucash/gnucash/master/src/report/standard-reports/advanced-portfolio.scm>.

I appreciate the fix, Mike. I am now getting VALUE=SHARES*PRICE in the 
report. I don't wish to be difficult, but would it not be better to use 
the alternate halfway algorithm to ensure that the Price used for the 
report's date is consistent with the same date appearing in the price 
editor? From a UI perspective it is bound to cause confusion to see 
2013-01-04 as $11 in the report but 2013-01-04 as $10 in the price 
editor, which is what I am seeing even with the fixed script.

Carl



More information about the gnucash-user mailing list