Splunk Search

How to create and extract values from multivalue field ?

karthi2809
Builder

Hello to all,

I have a multivalue field with a content.errormsg with values and also with a null value. If the null value in the fields it will not showing any results in the output
example:

errormsg
closed connection
Empty String
null


needed result:

errormsg
closed connection
Empty String
Labels (1)
0 Karma

marnall
Motivator

Sure thing, you can use the mvfilter eval function to get rid of the unwanted value in the multivalue field

 

| eval yourfield = mvfilter(yourfield != "null")

ITWhisperer
SplunkTrust
SplunkTrust

Do you mean something like this?

| eval errormsg=mvfilter(errormsg!="null")
Get Updates on the Splunk Community!

Exciting News: The AppDynamics Community Joins Splunk!

Hello Splunkers,   I’d like to introduce myself—I’m Ryan, the former AppDynamics Community Manager, and I’m ...

The All New Performance Insights for Splunk

Splunk gives you amazing tools to analyze system data and make business-critical decisions, react to issues, ...

Good Sourcetype Naming

When it comes to getting data in, one of the earliest decisions made is what to use as a sourcetype. Often, ...