Quantcast
Channel: Active questions tagged jq - Stack Overflow
Viewing all articles
Browse latest Browse all 657

Filtering out JSON properties where keys do not match length

$
0
0

I have JSON that looks like:

{"18003432343": ....,"18005553332": ....,"1-3-2025 10:36:41_08941100 AM": ....,"1-3-2025 11:36:41_08941100 AM": ....}

I would like to use JQ to filter out all keys where the key length does not equal to 11. So for the above input, the output should be:

{"18003432343": ....,"18005553332": ....}

What is the appropriate JQ command line for this?


Viewing all articles
Browse latest Browse all 657

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>