Re:Show HN: Querying JSON documents using SQL-like language ...
by bachmeier on Tuesday February 25, 2020 @04:45PM
(#22417823)
I personally find jq to be extremely complicated once you move beyond simple queries.
[ Parent
| on HN ]
Re:Show HN: Querying JSON documents using SQL-like language ...
by nexuist on Tuesday February 25, 2020 @06:02PM
(#22418482)
After having used jq for some heavy data processing (building an entire Markdown document from a huge slab of JSON with no external tools), I am inclined to agree.
However, I think this may be indicative of the task you are trying to complete rather than the tool itself. At a certain level of complexity your resulting code will just look bad regardless of which language you use. One thing jq does to make this easier is providing the pipe operator, so you can break a complex task into stages: A | B | (C .... | C.5) | D | E...
Re:Show HN: Querying JSON documents using SQL-like language ...
by benibela on Tuesday February 25, 2020 @06:43PM
(#22418778)
You could try my Xidel, based on XPath and JSONiq ( http://www.videlibri.de/xidel.html ).
It is more verbose for simple queries, but with named variables and functions, larger queries do not become complicated
Re:Show HN: Querying JSON documents using SQL-like language ...
by inshadows on Tuesday February 25, 2020 @10:05PM
(#22419904)
Xidel is my immediate pick for querying HTML. I use it in several scripts. Thanks!
I still prefer jq for JSON processing though. I'm hooked to pipelines. EDIT: The great power of jq is in transforming documents, not querying.
Re:Show HN: Querying JSON documents using SQL-like language ...
by kmelve on Wednesday February 26, 2020 @02:35AM
(#22421119)
You should try out GROQ (https://groq.dev) then!