ledger -f ledger.txt bal Assets -X EUR --now 2018-12-31 --unrealized
bal Assets
====================================================================
2018-01-01 Opening Balance
Assets:Checking 1000.00 USD
Equity:Opening Balances
P 2018-01-01 USD 1
EUR
P 2018-07-01 USD 1.5 EUR
==================================================================
ledger -f ledger.txt bal Assets -X EUR --now 2018-12-31 --unrealized
EUR1500 Assets:Checking
EUR-500 Equity:Unrealized Gains
--------------------
EUR1000
Here, I don't follow you. (Maybe I don't understand what an "income
statement-like" report is?)
ledger -f ledger.txt bal Assets Liabilities
ledger -f ledger.txt bal Income Expenses
- a single report
- that shows the change in your assets and Liabilities between two points in time
- grouped into Accounts (line with the balance) command
- which includes unrealized gains and losses
- where the total reflects the overall change
Expenses are tracked at the historical exchange rate (e.i. at the exchange rate, available during transaction). When exchange rate changes, Expenses and Income do not get re-calculated.
This is believed to be inline with conventional wisdom , that if you have consumed pizza for 10 USD, there is no reason to re-calculate how much this pizza is worth now in EUR, when USD/EUR exchange rate changed. It only makes sense to know how much that pizza was worth in EUR, when you consumed it.
Assets and Liabilities on the other side are recalculated with every event of exchange rate change.
This is also inline with conventional wisdom. If you own 1000 of Currency / stock XYZ and all of a sudden this currency became more expensive (just think of Bitcoin), this means you actually got reacher and you want to see it.
The exchange rate changes are taken care in the following way:
A special Commodity Revaluation transaction is logged. Following the principle of double-entry accounting
one shoulder of transaction is logged to corresponding Asset and / or Liability accounts to adjust these accounts to new exchange rate.
another shoulder is logged to special Gain due to commodity price change (trading account, using Peter Selinger’s terminology).
--
---
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+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
One would have to query ledger is different ways and paste together different parts of different reports, to get the situation as presented in Appendix A
To get Gain due to commodity price change (trading account)
ledger -f InputFile.txt bal Assets Liabilities --unrealized -X EUR
EUR2048 Assets:Payment
EUR-736 Equity:Unrealized Gains
--------------------
EUR1312
Note: the fact that ledger puts Assets / Liabilities and Unrealized gain in the same report and shows balance between then does not seem to make sense for me at the moment. It is not clear, what the resulting balance EUR1312 is meant to show. Any way, the unrealized gain is calculated as per Appendix A
To see the latest balance sheet-like report
ledger -f InputFile.txt bal Assets Liabilities -X EUR
EUR2048 Assets:Payment
To see the Expenses and Income and their balance
ledger -f InputFile.txt bal Expenses Income -X EUR -H
EUR288 Expenses:Shopping
EUR-600 Income:Salary
--------------------
EUR-312
Note: it there would be a way to add unrealized gains in this report, but NOT to include Assets and Liabilities, this would be exactly what I am looking for in terms of Income statement-like report, which shows all changes in one report
To list all changes to Assets and Liabilities including “Gain due to commodity price change”
ledger -f InputFile.txt reg Assets Liabilities -X EUR
18-Jan-01 Opening balance Assets:Payment EUR1000 EUR1000
18-Feb-01 Commodities revalued <Revalued> EUR200 EUR1200
18-Feb-02 Step 2 Shopping 1 Assets:Payment EUR-120 EUR1080
18-Feb-03 Step 3. Salary 1 Assets:Payment EUR600 EUR1680
18-Feb-04 Commodities revalued <Revalued> EUR280 EUR1960
18-Feb-05 step 5. Shopping wi.. Liabilities:CreditCard EUR-168 EUR1792
18-Feb-06 Commodities revalued <Revalued> EUR256 EUR2048
18-Feb-07 Step 7. Payment to .. Liabilities:CreditCard EUR192 EUR2240
Assets:Payment EUR-192 EUR2048