Dashboards & Visualizations

Xaxis data not showing up in a bar chart

sarithapguptha
Engager

Hi,

Please help, I want to get the xaxis values in a bar chart.
In the image attached, i have a query which doesnot have transpose command where I can see the values appearing for xaxis then when i tried to change the color for each bar using transpose command then suddenly the xaxis values does not appear.
In the query i m displaying top highest 10 values

alt text

Labels (1)
0 Karma
1 Solution

niketn
Legend

@sarithapguptha if you need color by each resource value as well as display the resource name in the x-axis, you should use | eval {resource}= cost after head 10, instead of using the transpose command.

Following is a run anywhere example for you to try out.

index=_internal sourcetype=splunkd log_level=INFO cumulative_hits=*
| stats sum(cumulative_hits) as cost by name
| sort - cost
| head 10
| eval {name}='cost'
| fields - cost
____________________________________________
| makeresults | eval message= "Happy Splunking!!!"

View solution in original post

0 Karma

niketn
Legend

@sarithapguptha if you need color by each resource value as well as display the resource name in the x-axis, you should use | eval {resource}= cost after head 10, instead of using the transpose command.

Following is a run anywhere example for you to try out.

index=_internal sourcetype=splunkd log_level=INFO cumulative_hits=*
| stats sum(cumulative_hits) as cost by name
| sort - cost
| head 10
| eval {name}='cost'
| fields - cost
____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

sarithapguptha
Engager

@niketn 

Thank you for the solution... it worked 😊

 

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 ...