Splunk Search

How to Display query result in text format,rather that a graph(chart or timechart)?)

geetanjali
Path Finder

Hello,

Thanks in advance.

I have one pie chart graph in a view having sum of power usage as per host.I want to display total power usage just below the pie chart. I want to display in text format. As of now, i am displaying in table format with following query :

index="test" sourcetype="test_usage" | chart sum(Power_consumption) as Total(W)

How could i display the result of this query in text format?

Geetanjali

Tags (1)
0 Karma

mw
Splunk Employee
Splunk Employee

How about using a Single Value element? You could, for extra credit :), also sprinkle in the rangemap command to have the Single Value show a green/yellow/red state based on the total consumption, if desired:

index="test" sourcetype="test_usage" | stats sum(Power_consumption) as total_pc | rangemap field=total_pc low=0-20 elevated=21-100 default=severe

Outside of that, I think you'd be hacking advanced xml to put a straight text value in there (but I'm not completely confident of that either).

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...