Is there any way to apply an automated transaction *to another automated
transaction*? Alternatively, does anyone have other ideas as to how I can
solve this issue?
Here's my situation: I use automated transactions for envelope-like
budgeting. After getting a paycheck, I remove money from my checking
account and place it into various funds accounts using a virtual
transaction. Then, based on the expense category of each transaction, money
is automatically subtracted from the virtual accounts. It looks something
like this:
= /Expenses:Transportation:Car:Gas/
[Assets:Funds:Transportation:Car:Gas] -1.0
[Assets:Bank:Checking] 1.0
2019/01/19 * Paycheck
[Assets:Funds:Transportation:Car:Gas] $ 30.00
; ...lots of other transactions
[Assets:Bank:Checking] $-1000.00
2019/01/31 * Kwik Trip
Expenses:Transportation:Car:Gas 10.000 gal {=$2.149}
Assets:Bank:Checking
This final transaction gets two automatic postings for $21.49, subtracting
from *[Assets:Funds:Transportation:Car:Gas]* and adding back to
*[Assets:Bank:Checking]* so that the balance of the checking account is
unchanged by the whole transaction.
(In reality there are several additional transactions to correctly handle
paying with credit cards or cash, and the matching is slightly more
complicated, but this should be enough to understand what's going on.)
Now I'm trying to add functionality for my state's use tax. Basically, if
you buy items out of state and the seller doesn't collect sales tax on
those purchase, you owe the state's sales tax on those items. So I want to
set aside the appropriate amount of money over the course of the year until
I pay it on my income tax return. The most basic version would look like
this:
= tag(usetax)
[Assets:Funds:Reserves:Use Tax] 0.06875 ; State tax
[Assets:Funds:Reserves:Use Tax] 0.005 ; County tax
[Assets:Bank:Checking] -0.07375
The problem with this is that the money is coming out of the wrong account.
If $5.00 in use tax is collected by the transaction, my checking balance
now stands at -$5.00. The money should be coming out of the appropriate
virtual *Assets:Funds* account that the purchase was billed to, so
something like this:
= /Assets:Funds/ & tag(usetax)
[Assets:Funds:Reserves:Use Tax] 0.06875 ; State tax
[Assets:Funds:Reserves:Use Tax] 0.005 ; County tax
[$account] -0.07375
Unfortunately, */Assets:Funds/* never matches anything because Ledger
evidently doesn't match other automated transactions in the predicate for
an automated transaction. The only other way I can think of to make this
work is adding a separate use-tax automated transaction for *every* expense
category, which is obviously ridiculous.
Any thoughts?
--
---
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].
For more options, visit https://groups.google.com/d/optout.