Hello,
Every week, I pay my babysitter a regular amount of cash: let's say
$50.00. I don't want to withdraw this from my checking account until
it's time to pay it, since it's insecure to keep cash lying around. But
I also want to see it in a different account so I can be sure not to
spend it. I also still have to be able to register the real ATM
withdrawal from checking account correctly.
My first inclination would be to do something like the following, with
virtual postings (there will be three Fridays between this paycheck and
the next one):
2012/09/13 BABYSITTER TRANSFER
[Assets:Babysitter Money] $50
[Assets:Babysitter Money] $50
[Assets:Babysitter Money] $50
[Assets:Banking:Checking]
2012/09/14 ATM WITHDRWL
;; $50 of spending money
Expenses:Cash $100
[Assets:Babysitter Money] $-50
Assets:Banking:Checking
2012/09/14 BABYSITTER
Expenses:Babysitter $50
Expenses:Cash
(I know I shouldn't be transfering from an expense, but it makes cash
easier to deal with.)
Now, this does what I want when I run it without "-R":
$ ledger reg "Checking"
12-Sep-13 BABYSITTER TRANSFER [Ass:Banking:Checking] $-150 $-150
12-Sep-14 ATM WITHDRWL Asset:Banking:Checking $-50 $-200
That is, it sees my checking account as having $200 less than when I
started: the $150 set aside for the babysitter, and the $50 for myself.
The problem, though, comes when I run it with "-R":
$ ledger reg "Checking" -R
12-Sep-14 ATM WITHDRWL Asset:Banking:Checking $-50 $-50
So it doesn't take the virtual $150 out. Good. But it also only takes
out $50 for the ATM withdrawal. If I'm not using the virtual postings,
shouldn't my ATM withdrawal be $100? That's how much money I *really*
took out of my checking account? It still seems to be balancing the
virtual transaction even when I ask it to only look at real
transactions.
The end result is that things don't balance to zero:
$ ledger bal -R
$-50 Assets:Banking:Checking
$100 Expenses
$50 Babysitter
$50 Cash
--------------------
$50
Am I using virtual transactions wrong in this case, is this just not a
situation they can handle, or is this a bug?
Thanks, as always,
Jesse