-
Notifications
You must be signed in to change notification settings - Fork 180
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Non-rooted expressions support #110
Comments
Not currently possible, but something I think would be useful. |
It's pretty necessary if you are working with JSON with an unknown schema but need to recognize subsets within it. I find it crops up when using JSON for metadata. I'm not sure how many folks need this – but it's a deal breaker for that kind of situation. |
Agreeing with DavidHess. |
I agree too, non-rooted expressions is the only real thing missing in JMESPath, something like a.**.b would be so nice. |
@jamesls would you propose a syntax for this to the JMESPath specification? even if it's not yet implemented, a proposed syntax would allow someone to produce a PR that does implement it for your review |
It's really missing.. Is there any changes in this direction since 2016? |
for the meantime, here is a bash function i use to search values in json with jq:
|
Upvote! |
@jamesls what are your thoughts on adopting the same recursive descent syntax as JSONPath and E4X, where I was going to switch from a Rust JSONPath library to the jmespath.rs library (after getting it modernized), but I need recursive descent for my use case. I serialize a lot of Rust data structures representing the vimwiki markup language into JSON. If I wanted to look up a tag, snippet of text, etc. I only know the subtree within JSON and not necessarily the full path. |
@chipsenkbeil We want to propose this feature to JMESPath and will include this in the next iteration for JMESPath Community. |
I may just be missing it, but it doesn't seem to be possible to do the equivalent of
//
in XPath. I.e. find the desired expression anywhere in the supplied JSON versus from the root of it. If not, can that be made a feature request?The use case is when you are trying to find subsets of JSON in a document whose overall structure you cannot predict in advance.
The text was updated successfully, but these errors were encountered: