Hi, folks. I had hoped this would be straightforward, but evidently not enough for me so far. I need your help.
My base currency is CAD and I have a bank account (call it "USD Bank") denominated in USD. My last year-end balance sheet has a CAD balance of "USD Bank" as CAD 815.57 and the bank statement has the USD balance of "USD Bank" as USD 835.44. Our convention is to use the monthly average foreign currency exchange rate from Bank of Canada when converting foreign currency transactions to CAD. Naturally, the CAD equivalent "balance" on this account has drifted from the amount you would get by converting the current USD balance into CAD.
Now I'm trying to start tracking this account with hledger. Here's what I have:
- P directives for the monthly average forex rates for each month of 2023 between USD and CAD
- an opening balance entry for "USD Bank" as 835.44 USD @@ 815.57 CAD
- I'm using --value="then,CAD" when I run the hledger tools
When I do this, the opening balance of "USD Bank" shows as 1144.55 CAD, which I infer is the correct conversion using the "--value=then,CAD" switch, but I need this opening balance to be 835.44 USD valued at 815.57 CAD in order to match the balance sheet moving forward.
What am I missing? What am I getting wrong? Do I have a fundamental problem in my mental model wanting to do this and use "--value=then,CAD"? How would I make it work to be able to use "--value=then" (which is convenient for other reasons) with an opening balance whose amounts don't match the then-in-use forex rate?