Splunk Search

Can you help me use the eval command with a wildcard question?

linuxology
New Member

Is there a way to do a search for any version that begins with a 5* in an eval search?

eval sofver = if (softwareversion=="5*", "Compliant", "Non-Compliant") chart count over system by sofver

I can get it to work with a specific version, say 5.2.1.5, but I need to figure out how to do anything with a 5.x.x.x

0 Karma

linuxology
New Member

Would you be able to tell me how to do a NOT Match?

0 Karma

sdchakraborty
Contributor

Hi,

Can you try the below,

eval sofver = if (match(softwareversion,"5*"), "Compliant", "Non-Compliant") 

Sid

0 Karma

linuxology
New Member

Would you be able to tell me how to do a match NOT?

0 Karma

sdchakraborty
Contributor

Just add NOT before match function ☺️

0 Karma
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

We're excited to announce the general availability of Scheduled Export for Dashboard Studio. Starting in ...

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...