Hi All,
I have created a table using stats command which displays store number, avgCPU, avg IOWAIT, avgRAM. For the avgCPU, avg IOWAIT and avgRAM i have given color based on the thresholds using the color bar from edit section(the paint brush symbol). I was trying to change the color of the Store Name cells based on the color in other cells i.e. if the color of any cell is red, Store Name cell should be red, if color of any cell is amber, Store Name cell should be in amber and if all the cells are green then the Store Name cell should be green. I cannot use js as i don't have access to config files . Is there any other was that i can use like condition maybe?
Hi @niks987,
Did you check out this documentation, you should be able to configure conditional formating from xml :
https://docs.splunk.com/Documentation/Splunk/7.2.6/Viz/TableFormatsXML#Color_format_rules
for example :
<colorPalette type="expression">if (value == "splunkd", "#65A637", "#0000CC")
</colorPalette>
Cheers,
David
Hi @niks987,
Did you check out this documentation, you should be able to configure conditional formating from xml :
https://docs.splunk.com/Documentation/Splunk/7.2.6/Viz/TableFormatsXML#Color_format_rules
for example :
<colorPalette type="expression">if (value == "splunkd", "#65A637", "#0000CC")
</colorPalette>
Cheers,
David
I believe @niketnilay may have answered this question under this answer: https://answers.splunk.com/answers/716558/add-colors-to-a-table-for-dynamic-columns.html#comment-716...
HI Damarling,
Thanks for replying.
Yes i have seen that, but i wanted to ask is there any other way to do it without using j query or js.
I have been trying to edit the XML file like changing the format section or doing changes using the brush option.
<format type="color" field="Store Number">
<colorPalette type="map">{"80":#F1813F,"90":#DC4E41}</colorPalette>
</format>
Something like this, i know this wont work, its just an example.
Thanks for your help.