Splunk Search

Summarize data per month

JandrevdM
Path Finder

Hi, I am trying to get a list off all users that hit our AI rule and see if this increase or decrease over the timespan of 90 days. I want to see the application they use and see the last three months display as columns with a count of amount of users. Example below

ApplicationsJune(Month1)July(Month2)August(Month3)
chatGPT213233512

 

index=db_it_network sourcetype=pan* rule=g_artificial-intelligence-access
| table user, app, date_month
```| dedup user, app, date_month```
| stats count by date_month, app
| sort date_month, app 0
| rename count as "Number of Users"
| table date_month, app, "Number of Users"
Labels (1)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust

Try this

index=db_it_network sourcetype=pan* rule=g_artificial-intelligence-access
| chart count by app date_month

View solution in original post

ITWhisperer
SplunkTrust
SplunkTrust

Try this

index=db_it_network sourcetype=pan* rule=g_artificial-intelligence-access
| chart count by app date_month

JandrevdM
Path Finder

Thanks!

Do you perhaps know how I can summarize count only a user once per month per app.

index=db_it_network sourcetype=pan* rule=g_artificial-intelligence-access
| table user, app, date_month
| dedup user,app, date_month
| chart count by app date_month
| sort app 0

This gives me a huge total for august but takes out the events for the other months

0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

What you have should work, but you could try this instead

index=db_it_network sourcetype=pan* rule=g_artificial-intelligence-access
| stats count by user app date_month
| chart count by app date_month
0 Karma

gcusello
SplunkTrust
SplunkTrust

Hi @JandrevdM ,

what's the issue in your search?

it seems to be correct, even if I'd semplify it:

index=db_it_network sourcetype=pan* rule=g_artificial-intelligence-access
| stats count by date_month app
| rename count as "Number of Users"
| table date_month app "Number of Users"

If you have many data to analyze, you could schedure this search, e.g. every night with the events of the day, saving results in a summary index and searching on the summary index.

Ciao.

Giuseppe

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