GNOME Bugzilla – Bug 725197
Balance Sheet Report calculates stock values incorrectly
Last modified: 2018-06-29 23:27:30 UTC
If I create a Balance Sheet, stock values are calculated incorrectly. For example, If I buy 300 shares of XYZ at $20.00, the asset value will be reported (correctly) as $6000.00. If the price of XYZ is later updated to $35.00, the asset value is still reported at $6000.00. I think the reported asset value should track the price of the stock. If I then sell 100 shares of XYZ at $40.00, the report shows the value of my XYZ holdings as $2000.00 (which seems to come from the initial investment, minus the proceeds of the sale, or $6000.00 - $4000.00). It should be the product of the remaining number of shares (200) and the price per share ($40.00), or $8000.00. If I sell another 50 shares at $40.00, the asset value goes to zero ($6000 - $4000 - $2000), even though I still have 150 shares which are worth $40 per share. If I sell another 100 shares at $50.00, the report shows a value of $5000, which is the sum of the proceeds of the three sales ($4000 + $2000 + $5000) minus the original cost ($6000). In other words, the calculated value of my asset seems to be abs( (sum of investments) - (sum of proceeds of sale) ) which is a meaningless number. Oddly enough, when I do sell all of my remaining shares, the asset value then goes to zero, abandoning the above formula.
I also observed that the "Unrealized Gain" in the report changes when I sell the remaining shares. But it does not change for any of the other transactions.
GnuCash bug tracking has moved to a new Bugzilla host. The new URL for this bug is https://bugs.gnucash.org/show_bug.cgi?id=725197. Please continue processing the bug there and please update any external references or bookmarks.