<div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><div dir="ltr" style="font-family:arial,sans-serif;font-size:12.8px"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">​<span style="font-family:monospace,monospace">Either I wasn't clear or you're misunderstanding what I'm saying, the "cost basis field" is the amount that is used to reduce the remaining basis of the asset.  If you sell the entire investment, the reduction would be the entire cost of the investment (thereby reducing the cost to zero).  The reason that you might need to adjust the cost basis is for exactly the reason that you pointed out: when you sell less than the full asset, there's more than one way to determine the cost of the part that was sold.  You can use "average cost", "FIFO", or "specific lots" (and probably some others) to determine the cost of the part that was sold.  A more sophisticated user interface for entering/determining the cost would be a refinement, this is just meant to be a first step along the way. The difference between the sales price and the cost basis of the part that was sold is the gain/loss on the sale.</span></div><div class="gmail_default"><font face="monospace, monospace"><br></font></div><div class="gmail_default"><font face="monospace, monospace">Creating a  "category" for storing the cost and/or recovering the cost doesn't make any sense, the cost is already stored in the investment account (the stock/bond account).  It contains the original amount (amounts if more than one purchase was done).  The difference between the sales price and the "cost basis" of the sale is the gain/loss on the transaction and that would go to one or more "categories".</font></div><div class="gmail_default"><font face="monospace, monospace"><br></font></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><span style="font-family:monospace,monospace">As far as developers with the time to implement it, when I said "I was thinking about implementing" I meant I was going to work on the implementation.</span>​</div></div><div class="" style="font-family:arial,sans-serif;font-size:12.8px"><div id=":1wg" class="" tabindex="0"><img class="" src="https://ssl.gstatic.com/ui/v1/icons/mail/images/cleardot.gif" style=""></div></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 23, 2016 at 3:14 AM, aga <span dir="ltr"><<a href="mailto:agander93@gmail.com" target="_blank">agander93@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On 22/05/16 20:04, Mitch Frazier wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
While entering a number of investment transactions recently I realized<br>
that KMM doesn't actually have a way to record the gain/loss on the sale<br>
of an investment. I was thinking about implementing something to solve<br>
this but wanted to pass the idea past the list first.<br>
<br>
As a first step at a solution, I was going to add a couple more rows to<br>
the transaction detail in the investment register:<br>
<br>
   - A cost basis field.  This would be an amount field that is<br>
     used to determine how much the cost of the investment is<br>
     reduced by the sale. Initially this field could be pre-filled<br>
     by the average cost (based on the number of shares being sold).<br>
     If the entire investment is sold, this field would be fixed<br>
     and not editable.<br>
   - A gain/loss field.  This would be an splitable account field<br>
     for entering the category or categories for the gain/loss.<br>
     Splits are useful for allowing both short-term and long-term<br>
     gain/loss specifications on a transaction.<br>
<br>
The current implementation "hides" the gain/loss because the balance of<br>
an investment shows as zero when the share value is zero, regardless of<br>
the amount the investment is sold for.  Whereas, since the gain/loss is<br>
not recorded anywhere, the balance ought to be negative if the<br>
investment was sold for a gain and positive if sold for a loss.<br>
<br>
Mitch<br>
<br>
</blockquote>
<br></div></div>
I think the developers will need to comment on this proposal.  From my own point of view, it is not a functionality that I need, at least at present.  What's more important, though, is that it might be advisable for display of the extra fields to be optional, certainly from the perspective of a new user.<br>
<br>
Allan<br>
<br>
</blockquote></div><br></div>