Yeah seems like a bug, definitely shouldn’t be handled that way IMO.

> On Mar 18, 2020, at 12:39 AM, [email protected] wrote:
> 
> It's not balancing because the realized gains and losses seem to be still 
> reported as "Unrealized" - I am trying to understand this myself.
> 
> Here is a simpler example ledger file (note the sale transaction has been 
> commented out):
> 
> 17/05/2010 XYZ Purchase
>   Assets:XYZ    100 XYZ {$10}
>   Assets:Bank   $-1000
> P 19/09/2019 XYZ $11
> comment
> 20/09/2019 XYZ Sale
>   Assets:XYZ    -100 XYZ {$10} @ $11
>   Assets:Bank   $1100
>   Income:Realised Gains
> end comment
> 
> Report based on above:
> $ ledger -f test.dat bal -V --unrealized
>                 $100  Assets
>               $-1000    Bank
>                $1100    XYZ
>                $-100  Equity:Unrealized Gains
> --------------------
>                    0
> 
> That looks OK.
> Now after uncommenting the sale transaction:
> $ ledger -f test.dat bal -V --unrealized
>                 $100  Assets:Bank
>                $-100  Equity:Unrealized Gains
>                $-100  Income:Realised Gains
> --------------------
>                $-100
> 
> Why is the unrealized gain still there?
> 
> Tim.
> 
> -- 
> 
> --- 
> 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 [email protected] 
> <mailto:[email protected]>.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/ledger-cli/2dacec44-0421-463d-acc7-9ff2f39abd21%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/ledger-cli/2dacec44-0421-463d-acc7-9ff2f39abd21%40googlegroups.com?utm_medium=email&utm_source=footer>.

-- 

--- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ledger-cli/98DF4126-211B-4465-AAE1-07D3A66BC498%40gmail.com.

Reply via email to