Splunk Search

How to add a unit with a value to a timechart?

chanduira
Explorer

Dear Experts,

We are trying to add unit with a value to a timechart.
My search is:

index = xyz sourcetype = csv source = "C:\\Users\\co*" | eval Capacity =IPDU1_power+IPDU2_power | timechart avg(Capacity) by Rackno 

This search will give an output like Capacity by Rack in timechart. I want to add "KW" unit with Capacity of each rack.

Please help I try with option

| eval Capacity=Capacity."KW" this did not work

0 Karma

somesoni2
Revered Legend

Once you add the string unit KW to the values, it becomes string which you can't plot (only numerical values for y axis). Better option would be to add unit in the y axis label.

0 Karma
Get Updates on the Splunk Community!

Modern way of developing distributed application using OTel

Recently, I had the opportunity to work on a complex microservice using Spring boot and Quarkus to develop a ...

Enterprise Security Content Update (ESCU) | New Releases

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

Archived Metrics Now Available for APAC and EMEA realms

We’re excited to announce the launch of Archived Metrics in Splunk Infrastructure Monitoring for our customers ...