Splunk Search

How to edit a time chart search to sort on count by date, rather than count by user?

bworrellZP
Communicator

Yesterday I was asked if I can swap out time chart, so that the time is on the top, and user name is on the left.

Background: I have a chart that shows users and count of logins by day. They want to be able to sort on the count by date rather than count by user.

Is there an easy way to change this?

Thanks

0 Karma
1 Solution

wpreston
Motivator

Try this:

...<your base search here>... | eval Date=strftime(_time, "%D") | chart count by User Date

View solution in original post

woodcock
Esteemed Legend

You can also use the transpose command.

0 Karma

wpreston
Motivator

Try this:

...<your base search here>... | eval Date=strftime(_time, "%D") | chart count by User Date
Get Updates on the Splunk Community!

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...