That’s a question that popped earlier this month :)

reg Expenses:Food -l "any(account =~ /Liabilities:Credit Card/)"

Note that it catches *any* other side, in case where your transaction
has more than two lines it works too.

(Mon, Jan 25, 2021 at 03:03:28PM -0800) Alan :
> Is there some way to select entries by matching each "side" of the 
> transaction?
> 
> For example, list expenditures to "Expenses:Food" but not all of them; only 
> the ones that were charged against "Liabilities:Credit Card."
> 
> I tried `ledger reg exp.*food and liab.*credit.card` but that turns up 
> nothing.
> 
> My workaround is to display "--related" and then pipe it to grep; but 
> sometimes that's not quite perfect.
-- 
Ismael

-- 

--- 
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/20210126001626.2yjoqjjdxfz6mm2r%40dilion.

Attachment: signature.asc
Description: PGP signature

Reply via email to