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

How to extract specific fields of JSON with jq based on partially match of one fileld?

$
0
0

Grafana log have this format.

{"log": "message","stream": "stdout","time": "2025-02-27T14:52:50.01405178Z"}

I need to extract all fields with the time equals to the current minute I can define with

--arg date "$(date '+%Y-%m-%dT%H:%M')"

.

How to use new date variable to select suitable records and then filter it by log field?


Viewing all articles
Browse latest Browse all 657

Trending Articles



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