Splunk Search

Count uniqe values over a certain period of time

Norling80
Path Finder

Hi

I´m trying to create a search that basically count the number of unique UserId generated over a certain time in the userlog, the UserId consist of 5 digits for example 12345 or 79365 etc.. need help to finalize it.

The search begins like this...
index=main sourcetype=userlog UserId="*" | ...?

regards
Magnus

Tags (1)
0 Karma
1 Solution

aweitzman
Motivator

| stats dc(UserId) should do the trick for you.

View solution in original post

Norling80
Path Finder

Thanks a lot, that worked.
/Magnus

0 Karma

aweitzman
Motivator

| stats dc(UserId) should do the trick for you.

Get Updates on the Splunk Community!

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

Splunk is officially part of Cisco

Revolutionizing how our customers build resilience across their entire digital footprint.   Splunk ...

Splunk APM & RUM | Planned Maintenance March 26 - March 28, 2024

There will be planned maintenance for Splunk APM and RUM between March 26, 2024 and March 28, 2024 as ...