Skip to content

Commit

Permalink
Document keywords "any" and "all"
Browse files Browse the repository at this point in the history
Fixes #1192
  • Loading branch information
tbm committed Jul 6, 2018
1 parent 34a4929 commit 9123a32
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions doc/ledger3.texi
Expand Up @@ -8159,6 +8159,19 @@ posting.
A regular expression that matches against the transaction code (the
text that occurs between parentheses before the payee).

@item expr any(KEYWORD =~ /REGEX/)
The @command{any} keyword is used to specify that at least one posting of
the transaction must match the expression in brackets. For example,
@samp{ledger -f d reg expr "any(account =~ /Assets:/)"} can be used to
display all transactions which involve at least one @samp{Assets:}
account.

@item expr all(KEYWORD =~ /REGEX/)
The @command{all} keyword is used to specify that all postings of a
transactions must match the expression in brackets. For example,
@samp{ledger -f d reg expr "all(account =~ /Assets:/)"} can be used to
display all transactions where all accounts are @samp{Assets:}.

@end table

The @command{query} command can be used to see how Ledger interprets
Expand Down

0 comments on commit 9123a32

Please sign in to comment.