Lognalytics

Menu
  • Home
  • Splunk
    • Splunk Administration
    • Splunk Development
    • Splunk Interview
    • Splunk Monitoring
  • Certification
    • Splunk
  • Contact
  • Privacy Policy

Switch to the dark mode that's kinder on your eyes at night time.

Switch to the light mode that's kinder on your eyes at day time.

Follow us
  • facebook
  • twitter
  • instagram
  • youtube
  • telegram
Search
Menu

Lognalytics

Login

Latest stories

  • Optimizing Storage Costs with Splunk SmartStore

    Optimizing Storage Costs with Splunk SmartStore

  • Splunk Cloud Victoria vs Classic Experience

    Splunk Cloud Victoria vs Classic Experience

  • summary indexing in splunk

    The Power of Summary Indexing in Splunk

  • renew splunk certificate

    Renew Splunk Certificates

  • Exploring the Reverse Command in Splunk

    Exploring the Reverse Command in Splunk

  • Changing Splunk Web Port

    Changing Splunk Web Port from 8000 to 443

Previous Next
in Splunk Development

LoveLove

Accum Command in Splunk

Understanding splunk accum command with an example

by Lognalytics Technology November 30, 2021, 10:46 am 67 Views

  • Facebook
  • LinkedIn
  • WhatsApp
  • Telegram
  • Twitter
accum command in splunk
accum command in splunk

For each event where field is a number, the accum command in splunk calculates a running total or sum of the numbers. The accumulated sum can be returned to either the same field, or a new field that you specify.

Syntax for accum command in splunk:

accum <field> [AS <newfield>]

Query before using accum command:

index=* sourcetype="WinEventLog:*"
| stats count by LogName EventType
| fields - count

Result before using accum command:

accum command

Query after using accum command:

index=* sourcetype="WinEventLog:*"
| stats count by LogName EventType
| accum EventType as Total

Result after using accum command:

accum command in splunk

Explanation:

The Accum command is used to calculate the running total as data comes in, that is it takes the value in a new field and sums it with the recently camed value of the original field on which the calculation needs to be done and calculates the total.

In the above results we are calculating the EventType values by LogName further we are calculating the running total that is each row value is added with the values in the next rows and at the end the total is calculated in a new field.

Also look for Append Command in Splunk

Click here

If you are still facing issue regarding this topic Feel free to Ask Doubts in the Comment Box Below and Don’t Forget to Follow us on social platforms, happy Splunking >😉

  • Facebook
  • LinkedIn
  • WhatsApp
  • Telegram
  • Twitter

Newsletter

Want more stuff like this?

Get the best viral stories straight into your inbox!

Don't worry, we don't spam

What do you think?

4 Points
Upvote Downvote

splunksplunk commandssplunk dev

What's Your Reaction?

  • LoveLove
    4
    Love
  • AngryAngry
    0
    Angry
  • SadSad
    0
    Sad
  • HappyHappy
    0
    Happy

You May Also Like

  • Exploring the Reverse Command in Splunk

    LoveLove

    in Splunk Development

    Exploring the Reverse Command in Splunk

  • stats count to include zero count

    Popular

    in Splunk Development

    Stats count to include zero count in splunk

  • Datamodel Command in Splunk

    Trending Popular HappyHappy

    in Splunk Development

    Datamodel Command in Splunk

  • Dedup Command in Splunk

    Popular

    in Splunk Development

    Dedup Command in Splunk

  • bin command in splunk

    Popular

    in Splunk Development

    Bin Command Splunk

  • addinfo command in splunk

    Popular LoveLove

    4 Shares

    in Splunk Development

    Addinfo Command in Splunk

More From: Splunk Development

  • summary indexing in splunk

    The Power of Summary Indexing in Splunk

    by Lognalytics Technology March 10, 2024, 7:27 pm

  • Exploring the Reverse Command in Splunk

    LoveLove

    Exploring the Reverse Command in Splunk

    by Lognalytics Technology December 28, 2023, 1:01 pm

  • stats count to include zero count

    Popular

    Stats count to include zero count in splunk

    by Lognalytics Technology July 12, 2022, 5:15 pm

  • Datamodel Command in Splunk

    Trending Popular HappyHappy

    Datamodel Command in Splunk

    by Lognalytics Technology January 25, 2022, 9:24 am

  • Dedup Command in Splunk

    Popular

    Dedup Command in Splunk

    by Lognalytics Technology January 21, 2022, 6:58 am

  • bin command in splunk

    Popular

    Bin Command Splunk

    by Lognalytics Technology January 19, 2022, 2:19 pm

Leave a ReplyCancel reply

Your email address will not be published. Required fields are marked *

GIPHY App Key not set. Please check settings

Don't Miss

  • Splunk Cloud Victoria vs Classic Experience

    Trending

    3 Shares

    Splunk Cloud Victoria vs Classic Experience

    by Lognalytics Technology December 17, 2024, 3:55 pm

  • splunk interview questions

    Trending Popular LoveLove

    4 Shares

    Common Splunk Interview Questions

    by Lognalytics Technology December 6, 2021, 6:12 am

  • Dedup Command in Splunk

    Popular

    Dedup Command in Splunk

    by Lognalytics Technology January 21, 2022, 6:58 am

  • bin command in splunk

    Popular

    Bin Command Splunk

    by Lognalytics Technology January 19, 2022, 2:19 pm

  • splunk interview questions for admin

    LoveLove

    4 Shares

    Splunk Interview Questions for Admin

    by Lognalytics Technology December 6, 2021, 7:49 am

  • stats count to include zero count

    Popular

    Stats count to include zero count in splunk

    by Lognalytics Technology July 12, 2022, 5:15 pm

append command in splunk

Append Command in Splunk

configuring in deploymentclient in splunk

Configure Deployment Client Splunk

© Copyrights 2023 Lognalytics | All Rights Reserved by Lognalytics Technology LLP.

Back to Top
Close
  • Home
  • Splunk
    • Splunk Administration
    • Splunk Development
    • Splunk Interview
    • Splunk Monitoring
  • Certification
    • Splunk
  • Contact
  • Privacy Policy
  • facebook
  • twitter
  • instagram
  • youtube
  • telegram
  • Facebook
  • LinkedIn
  • WhatsApp
  • Telegram
  • Twitter

Add to Collection

  • Public collection title

  • Private collection title

No Collections

Here you'll find all collections you've created before.

Login

Lost password?