On Thu, May 2, 2019 at 6:28 PM Alen Šiljak <[email protected]> wrote:
> Could someone clarify the effects of @@ syntax in trades, compared to @
> syntax? I have gone through a few documents related to trading and
> inventories, and none of them seem to contain the "@@" term.
>
It's just a shorthand to specify the total price instead of the per unit
price, when doing a price conversion.
100 USD @@ 125 CAD
is the same as
100 USD @ 125/100 CAD
The GnuCash export script spits out all trades in "100 VHY @@ 320 AUD"
> format. For this reason, queries and fava reports were confusing to me,
> since there is no cost basis nor the present/market value.
>
For cost basis you need to use the {...} syntax.
@ and @@ price conversions don't involve any cost basis.
They are two different types of things.
- Use price conversions when converting currencies
- Use cost basis when buying / selling investments
> From this, I would conclude that the @@ syntax is not the same as @ one.
> The @ syntax adds the price - cost basis and establishes the lot. The @@
> syntax does not seem to do that at all.
>
@ and @@ do almost the same thing - a price conversion.
{...} is how you attach cost basis to lots.
>
> A potential problem in that regard will be getting the correct price due
> to the rounding. Looking at the GnuCash schema, the price is also not kept,
> similar to BeanCount. There is a Quantity (i.e. 100 units of account
> commodity, in this case VHY), and Value (320 units of transaction
> commodity, in this case AUD). This is my assumption and the whole process
> seems a bit convoluted.
>
> In order to try to keep the compatibility, I will calculate the price
> during the export process. This will be limited to non-currency commodities
> only.
> However, I'd like to know the effects of one vs the other approach to data
> export.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Beancount" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/beancount/82276fa7-f4f8-4683-83f5-92b93559224d%40googlegroups.com
> <https://groups.google.com/d/msgid/beancount/82276fa7-f4f8-4683-83f5-92b93559224d%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
--
You received this message because you are subscribed to the Google Groups
"Beancount" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/beancount/CAK21%2BhOWY-MdLaKQSnBrUa4gbvAjSvrLeN%3D7UMg0p_%3Dnns7wOw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.