Splunk Search

Need a sum

Michael_Schyma1
Contributor

sourcetype="MFApps" | addtotals fieldname=sum |top limit=1 sum | fields + count | rename count AS "Number of Events

This is my search and all I want is one field that lists the total number of events. It does not seem to be keeping a sum of all events. Instead it just seems to be keeping the highest event number.

Tags (1)
0 Karma
1 Solution

cphair
Builder

Use stats count.


sourcetype="MFApps" | stats count as "Number of Events"

View solution in original post

cphair
Builder

Use stats count.


sourcetype="MFApps" | stats count as "Number of Events"

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

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...