Splunk Search

Can someone help me chart JSON values?

sarnathkj
Explorer

I have a JSON just like this. I want to chart data of the values inside values key. The keys of the data in the values will be dynamic.

{"Domain":"DotComMobile","Metrics":"regionCode","values":{"NY":563,"FL":270,"NJ":265,"PA":256,"MA":223,"CA":214,"VA":164,"MD":163,"TX":155,"OH":151}}

How would that be achieved?

0 Karma

richgalloway
SplunkTrust
SplunkTrust

Perhaps this will get you started.

<base search> | extract kvdelim=":" pairdelim=",}" | timechart latest(values.*) as *
---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...