Dashboards & Visualizations

Increment Count Totals over a Line Chart

jzwulf
Engager

I have a set of data that has a data field inside that shows when an asset has been assigned. Right now, we're pulling the total count of those assets, but have been asked to show an incrementing count over the course of a line chart.

The data looks something like this:

Asset IDAssigned Date
1237/12/21
1247/12/21
1257/13/21
1267/14/21

 

I want the data in the chart to show like this:

  • 7/12/21: 2
  • 7/13/21: 3
  • 7/13/21: 4

Essentially, after each date from the start, the chart adds the previous dates, and charts the total. 

Thanks in advance. 

Labels (1)
0 Karma
1 Solution

kamlesh_vaghela
SplunkTrust
SplunkTrust

@jzwulf 

Can you please try this?

YOUR_SEARCH
| streamstats count 
| eventstats max(count) as m by Assigned_Date | where count=m
| table Assigned_Date count

 

My Sample Search :

| makeresults | eval _raw = "Asset ID	Assigned Date
123	7/12/21
124	7/12/21
125	7/13/21
1254	7/13/21
126	7/14/21"| multikv forceheader=1
| table Asset_ID Assigned_Date
| rename comment as "Upto Now is sample data only"
| streamstats count 
| eventstats max(count) as m by Assigned_Date | where count=m
| table Assigned_Date count


 

Thanks
KV
▄︻̷̿┻̿═━一   ?

If any of my reply helps you to solve the problem Or gain knowledge, an upvote would be appreciated.

View solution in original post

ITWhisperer
SplunkTrust
SplunkTrust
| streamstats dc(AssetID) by AssignedDate
0 Karma

kamlesh_vaghela
SplunkTrust
SplunkTrust

@jzwulf 

Can you please try this?

YOUR_SEARCH
| streamstats count 
| eventstats max(count) as m by Assigned_Date | where count=m
| table Assigned_Date count

 

My Sample Search :

| makeresults | eval _raw = "Asset ID	Assigned Date
123	7/12/21
124	7/12/21
125	7/13/21
1254	7/13/21
126	7/14/21"| multikv forceheader=1
| table Asset_ID Assigned_Date
| rename comment as "Upto Now is sample data only"
| streamstats count 
| eventstats max(count) as m by Assigned_Date | where count=m
| table Assigned_Date count


 

Thanks
KV
▄︻̷̿┻̿═━一   ?

If any of my reply helps you to solve the problem Or gain knowledge, an upvote would be appreciated.

jzwulf
Engager

Changed it a bit to fit our actual fields, but this got us there! Thanks a bunch!

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Why Splunk Customers Should Attend Cisco Live 2026 Las Vegas

Why Splunk Customers Should Attend Cisco Live 2026 Las Vegas     Cisco Live 2026 is almost here, and this ...

What Is the Name of the USB Key Inserted by Bob Smith? (BOTS Hint, Not the Answer)

Hello Splunkers,   So you searched, “what is the name of the usb key inserted by bob smith?”  Not gonna lie… ...

Automating Threat Operations and Threat Hunting with Recorded Future

    Automating Threat Operations and Threat Hunting with Recorded Future June 29, 2026 | Register   Is your ...