Last active
July 30, 2022 18:46
-
-
Save palashkulsh/a85b236d69e77be7b8a64465372dc302 to your computer and use it in GitHub Desktop.
jq new usages
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[{pincode:1,value:1},{pincode:2,value:2}] | |
to | |
{1:{pincode:1,value:1},2:{pincode:2,value:2}} | |
jq '.| map({(.pincode|tostring): .}) | add' IN.json > pincode_wise.json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment