Note 1: This conversation primarily focuses on new features and improvements in JQ v2. For a more general introduction to JSONQuery see the “Resources” section at the beginning of part 1.
Note 2: JSONQuery v2 is available here — https://github.com/steve-ssh/FMP_JSONQuery.
Continuation of JQ v2 conversation with Steve Senft-Herrera
Kevin Frank: There are a couple little improvements in v2 we haven’t mentioned yet. Is this a good time?
Steve Senft-Herrera: Sure.
KF: Okay, thanks. One that I really like is that you can now use “=” in place of “EQUALS” — you don’t have to, but you can. In v2 either of these will work…
JSONQuery ( $input ; "region" ; "EQUALS" ; "Asia" ; "" ; "name" )
or
JSONQuery ( $input ; "region" ; "=" ; "Asia" ; "" ; "name" )
KF: …whereas in v1 you had to write out “EQUALS”.
SSH: Yeah, I like that one too.
KF: Another improvement is that when “MATCH_ALL” is your Operator, you can now simply leave that argument blank. As per ex. 197 in the example file, these two statements are equivalent.

and

SSH: It’s a small change, but I like it because there is less to distract the eye from what really matters in the calculation: your input JSON, and the desired key or path to harvest — in this case, “address”.
KF: Completely agree.
The MAP Component
KF: You know there is an absolute favorite item on my list that hasn’t been mentioned yet, and it has to do with the simplification of MAP syntax.
SSH: That is definitely right there at the top of my list of favorite features also. Continue reading “JSONQuery v2 Conversation with Steve Senft-Herrera, part 2”








