Splunk Search

How to count number of values in multi-valued field?

marinella26
Explorer

Hello!

I want to know how to count numbers of field values.

Currently I have two fields, something like:

User - Anna
Class - Math, Science, English

The “Class" field is a multivalued field, and i want the output to be something like this:

User - Anna
Class - Math, Science, English

Class_Number - 3

 

Is there an easy way to count how many values are in a multivalued field and show it?

Thanks in advance!

Labels (6)
0 Karma
1 Solution

marinella26
Explorer

Thank you so much!!

0 Karma
Get Updates on the Splunk Community!

Modern way of developing distributed application using OTel

Recently, I had the opportunity to work on a complex microservice using Spring boot and Quarkus to develop a ...

Enterprise Security Content Update (ESCU) | New Releases

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

Archived Metrics Now Available for APAC and EMEA realms

We’re excited to announce the launch of Archived Metrics in Splunk Infrastructure Monitoring for our customers ...