Splunk Search

How to add values to a chart with another color based on a certain value?

chadman
Path Finder

I have a chart that show some ping times. I would like to show values with "NA" as red in the chart and set their values to 1000. Currently they just show up as zero. Here is my current search.

sourcetype="mysearch" host=host123*  | timechart avg(internal_time) as "Ping Time"
0 Karma
1 Solution

somesoni2
Revered Legend

Try like this

your current search | replace "NA" with 1000 in "Ping Time"

Give the solution from below post for colors
https://answers.splunk.com/answers/58335/change-chart-bar-color-based-on-data-value.html

View solution in original post

0 Karma

somesoni2
Revered Legend

Try like this

your current search | replace "NA" with 1000 in "Ping Time"

Give the solution from below post for colors
https://answers.splunk.com/answers/58335/change-chart-bar-color-based-on-data-value.html

0 Karma

somesoni2
Revered Legend

Do you get a series/column named "N/A" ?

0 Karma

chadman
Path Finder

Currently I don't. I just see a bar chart with "Ping Time". If the value is not a number and is "NA" it shows up at 0 on my chart. I would like that so how up in red and have a value of 1000 instead of "NA"

0 Karma
Get Updates on the Splunk Community!

Introducing Splunk Enterprise 9.2

WATCH HERE! Watch this Tech Talk to learn about the latest features and enhancements shipped in the new Splunk ...

Adoption of RUM and APM at Splunk

    Unleash the power of Splunk Observability   Watch Now In this can't miss Tech Talk! The Splunk Growth ...

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...