[GNC-dev] New balsheet (and P&L report), API considerations, and (slow?) KVP in Account.cpp

Adrien Monteleone adrien.monteleone at lusfiber.net
Mon Aug 13 11:33:31 EDT 2018


Mailman was hungry. It ate your screenshots.


> Chris,
> To demonstrate the price difference on assets creating an “Unrealized Gain” line, I created a fake account with Trading Accounts off and purchased on 1 January 100 shares of a stock for $100, then created a new price for the stock of $200. The resulting Balance Sheet report is the first screenshot below. Price source is set to “nearest in time”.
> I repeated the process in a new book with trading accounts enabled and got the second screenshot. As you pointed out, the “Unrealized Gains” line changes to “Trading Gains”. Selling the stock made no difference on the report unless I also booked the 10,000 gain to Income:Short Term Cap Gains, after which the calculated line became “Retained Earnings” as illustrated by the third screen shot.
> I went back and did the sale on the non-trading-accounts book and found that indeed “Unrealized Gains” didn’t change after I sold the stock; that’s wrong, it’s a realized gain at that point. Booking the gain to Income changed the line to “Retained Earnings” as it did with trading accounts enabled and as expected.
> Finally, to illustrate the effect of price source I removed the sell transaction and changed the price source in report options to “Avg Cost”. The result is the last screenshot, showing the stock at book value and the “Unrealized Gains” line at 0.
> Regards,
> John Ralls
> _______________________________________________
> gnucash-devel mailing list
> gnucash-devel at gnucash.org
> https://lists.gnucash.org/mailman/listinfo/gnucash-devel

More information about the gnucash-devel mailing list