On Thu, May 7, 2020 at 11:07 PM John Wiegley <jwieg...@gmail.com> wrote:
>
> >>>>> "JS" == Joel Swanson <jkep...@gmail.com> writes:
>
> JS> Does posting order affect stock or commodity cost basis in Ledger?
>
> JS> Is that really the desired behavior, where changing the order of postings
> JS> changes the items for which ledger tracks lots? Does this have something
> JS> to do with which postings are considered primary and secondary in a
> JS> transaction with three or more postings?
>
> Yes, that is actually the reasoning. The first posting establishes the
> secondary commodity, while the second is the primary.
>
> You can avoid this confusing by not using the auto-calculation logic, and
> identifying your lots explicitly:
>
>     2004/05/01 Stock purchase
>         Expenses:Broker:Commissions        $19.95
>         Assets:Broker                     50 AAPL {$30.00} [2004/05/01] 
> (<TransactionId>) @ $30.00
>         Assets:Broker                  $-1,519.95
>
> If you use this fully elaborated lot specification everywhere, then you'll
> always know what Ledger is based its numbers on. Generally when I sell a
> commodity I just copy the details from the opening transaction.
>
Mr John

Have been thinking about this <Transactionid> and where you have
placed it in the
layout of the transaction. To me this is not too dissimilar to
'different' currency
transactions (items are purchased in a different than 'home' currency)
when I want
to track the costs of and in the transaction. I usually put the
various 'rates' in the
'notes' files ( right after the payee line then the next line using
the ; rate 234.15).

The example here you are putting the <Transactionid> inside the
transaction information.
Would you also use this technique in a currency exchange transaction
(transaction done
in a different currency than the ledger's 'base currency)?

Regards

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"Ledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ledger-cli+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ledger-cli/CAPpdf59e7F%3D32j3fQnriofJzbJKkoQoYPOZJ_fEf2k8-LaS%2B1Q%40mail.gmail.com.

Reply via email to