JSONPath Filter Expressions: Operators, Examples and Gotchas
How [?(...)] filters work: comparisons, && and ||, testing for a property, comparing against another path, and the cases where implementations differ.
Topic
7 articles tagged “json”.
How [?(...)] filters work: comparisons, && and ||, testing for a property, comparing against another path, and the cases where implementations differ.
A JSON sample is one snapshot, so a generated interface is a guess. What converters get wrong with null, missing fields, empty arrays and strings.
JSONPath selects values and is built into many tools. jq transforms JSON on the command line. The same queries in both, and how to choose.
JSON objects have no order, so a text diff reports changes that are not changes. How to sort keys first, what still differs, and three ways to do it.
In YAML 1.1, NO becomes false. Tested YAML 1.1 and 1.2 results for yes/no, octal, 22:22, version numbers and merge keys, and how to convert safely.
JSON looks like a JavaScript object literal, so people assume they behave identically. Undefined, dates, key order and duplicate keys all say otherwise.
A JSON document can parse perfectly and still have the wrong shape. Here is the difference between syntax and schema validation, and when you need both.