Splunk Search

How to calculate the total number of words in a sentence ?


The end result has to be like this

0 Karma


Try this. It assumes you've already extracted the sentence into the field "sentence".

... | eval count=mvcount(split(sentence," ")) | ...
If this reply helps you, an upvote would be appreciated.
0 Karma
State of Splunk Careers

Access the Splunk Careers Report to see real data that shows how Splunk mastery increases your value and job satisfaction.

Find out what your skills are worth!