Thanks a lot this seems to work! On Tuesday, 28 December 2021 at 05:25:23 UTC+5:30 Martin Michlmayr wrote:
> * Yashovardhan <[email protected]> [2021-12-27 11:06]: > > It seems like using hyphens (-) in commodity names causes ledger to > > have problems with limit and other queries. > > > For example, ledger reg -l 'commodity == "ABC-Fund"' should output 3 > postings but has no output. > > In your query, the " quotation mark is used to quote the string. But > since it's a quoted commodity, you also need to specify the quotes for > the commodity. Therefore, you need two quotation marks, like this: > > ledger -f d reg -l 'commodity == "\"ABC-Fund\""' > > > Please let me know if there are any set of valid characters for > > commodity names. Currently, using underscore (_) instead of hyphen > > (-) seems to be a quick fix. > > https://www.ledger-cli.org/3.0/doc/ledger3.html#Commoditized-Amounts > > -- > Martin Michlmayr > https://www.cyrius.com/ > -- --- 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/7a820da2-4f1b-4b8f-a37a-db3426450a16n%40googlegroups.com.
