Splunk Search

Can you help me figure out why my query is not working?

VijaySrrie
Builder
index=* |stats count by sourcetype |table index sourcetype count

The above query displays the sourcetype and count details, but not the index details, Please help me figure out how to proceed.

Tags (1)
0 Karma
1 Solution

vnravikumar
Champion

Hi

try like

index=* |stats count by sourcetype, index

View solution in original post

0 Karma

amiracle
Splunk Employee
Splunk Employee

You might want to look at this free course as well: https://www.splunk.com/en_us/training/free-courses/splunk-fundamentals-1.html

0 Karma

vnravikumar
Champion

Hi

try like

index=* |stats count by sourcetype, index
0 Karma

skoelpin
SplunkTrust
SplunkTrust

Fixed.. Don't use index=* when searching over index time fields

| metasearch 
| stats count by sourcetype, index
0 Karma

VijaySrrie
Builder

|metasearch index=* | stats count by sourcetype, index

is working fine

0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to May Tech Talks, Office Hours, and Webinars!

Take a look below to explore our upcoming Community Office Hours, Tech Talks, and Webinars this month. This ...

They're back! Join the SplunkTrust and MVP at .conf24

With our highly anticipated annual conference, .conf, comes the fez-wearers you can trust! The SplunkTrust, as ...

Enterprise Security Content Update (ESCU) | New Releases

Last month, the Splunk Threat Research Team had two releases of new security content via the Enterprise ...