Dashboards & Visualizations

Change the color of cell based on the condition in other cell

khojas02
Engager

Hi All,

I have a table something like this

MetricID                             Count                     Percent

AA                                        1404                       4%

BB                                         256                         13%

CC                                         749                        31%

Now, for each MetricID, I have some condition and based on that condition I would like the background color of Count and Percent columns to be changed to Green, Yellow and Red. Is it possible to do with Splunk?

Essentially I don't want to change the color of entire Count of Percent column, rather based on the condition for each MetricID, I would like to change the color for respective Count and Percent values.

Thanks in advance!!

Labels (1)
0 Karma

niketn
Legend

@khojas02 yes this would be possible with Splunk. Could you elaborate on the conditions that are possible with Metrics ID?

Please refer to following couple of answers which document three options to do it depending on whether you want to use JS or not.

https://community.splunk.com/t5/Dashboards-Visualizations/How-do-you-highlight-a-table-cell-based-on...

https://community.splunk.com/t5/Dashboards-Visualizations/How-to-change-font-color-based-on-a-condit...

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

anilchaithu
Builder

@khojas02 

you have to use simple js& css code to change the color of the row. Splunk dashboard examples has the sample code (table row highlighting). you can use that

https://splunkbase.splunk.com/app/1603/

 

hope this helps.

0 Karma
Get Updates on the Splunk Community!

Upcoming Webinar: Unmasking Insider Threats with Slunk Enterprise Security’s UEBA

Join us on Wed, Dec 10. at 10AM PST / 1PM EST for a live webinar and demo with Splunk experts! Discover how ...

.conf25 technical session recap of Observability for Gen AI: Monitoring LLM ...

If you’re unfamiliar, .conf is Splunk’s premier event where the Splunk community, customers, partners, and ...

A Season of Skills: New Splunk Courses to Light Up Your Learning Journey

There’s something special about this time of year—maybe it’s the glow of the holidays, maybe it’s the ...