Implementing proper cost basis tracking for shares

Dave Peticolas
Thu, 19 Oct 2000 22:43:02 -0700

Robert Graham Merkel writes:
> As I understand it, you don't have to *always* use LIFO
> or FIFO or some fixed rule for doing this - you can pick and choose,
> and as I understand things you can pick an arbitrary division for any
> particular share sale - and people do, because it can have subsantial 
> tax implications.  There are presumably rules about this kind of
> thing, but I don't know them and GnuCash doesn't need to know them.

Ahh, right, then we would have to remember the table from one
invocation to the next, otherwise the user would have to keep entering
it. But, we could defer the entry of that information until the report
needs to be generated, right? Doing it every time you enter a stock
transaction would be a burden, I think.

>  > > The next question is "how do we track income and expenses related to
>  > > a particular share account?", such as dividend payments, brokerage
>  > > fees and the like.  My initial suggestion is for each share account
>  > > to contain a "accounts containing income/expense transactions
>  > > related to this account" list, and each transaction related to
>  > > a share account should have a "Hi, I'm a <share account foo>
>  > > transaction".  The other alternative is to insist that dedicated
>  > > account(s) be set up so that every expense and all income related
>  > > to trading a particular stock should be placed in those accounts.
>  > 
>  > It starts to get complicated, but maybe there's no other way around
>  > it. Should the "Hi, I'm a ..." tag be for transactions or splits?
>  > Example: you buy x shares of A and y shares of B with one check,
>  > with two brokerage fees, one for A and one for B.
>  > 
> You're right, I think.  The tag should be at the split level if we go
> that way.  Do you think that the tag scheme is the better way to go?

I'm not sure. It's more flexible, but also ends up possibly being more
work for the user, as you would have to indicate that information over
and over, rather than picking an account which is always linked to a
stock account.

If the number of linked accounts is small (say one for expenses and
one for income), I think I would lean towards using linked accounts,
which we could prompt the user to create when the stock account is