Splunk Search

Problem with a wildcard in a field name

terryloar
Path Finder

This works: | chart count(eval(file_date="invalid")) AS "Invalid Date Syntax"
It returns "6"

This doesn't work: | chart count(eval(*_date="invalid")) AS "Invalid Date Syntax"
It returns "0"

The documentation sez its suppose to work.

Any ideas?

Tags (1)
0 Karma

dart
Splunk Employee
Splunk Employee

Does this work:

 | chart count(eval(searchmatch("*_date=\"invalid\""))) AS "Invalid Date Syntax"
0 Karma

martin_mueller
SplunkTrust
SplunkTrust

What doc would that be? I'd have expected eval to treat the asterisk as multiplication.

0 Karma
Get Updates on the Splunk Community!

Routing logs with Splunk OTel Collector for Kubernetes

The Splunk Distribution of the OpenTelemetry (OTel) Collector is a product that provides a way to ingest ...

Welcome to the Splunk Community!

(view in My Videos) We're so glad you're here! The Splunk Community is place to connect, learn, give back, and ...

Tech Talk | Elevating Digital Service Excellence: The Synergy of Splunk RUM & APM

Elevating Digital Service Excellence: The Synergy of Real User Monitoring and Application Performance ...