Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • When I run the command # /usr/bin/jq --argjson states "$state_map" '.[].Instances[] |= . + {"State": ($states[.InstanceId] // "unknown")}' SomeFile1.json", the error is as below: /usr/bin/jq: invalid JSON text passed to --argjson Use /usr/bin/jq --help for help with command-line options, or see the jq manpage, or online docs at stedolan.github.io/jq Commented Oct 11, 2018 at 3:41
  • Did you execute the previous command that sets the states_map variable? Commented Oct 11, 2018 at 11:57
  • I found this answer very useful. I learned a little more about jq. Thank you. Commented Jan 28, 2020 at 21:13