Splunk Search

How to show the mapped field when using map

aohls
Contributor

I am attempting to use the map command and table the data. I am trying to map in values to run through the a predict function and table the results. I get 90% there except the fields that are predicted do not populate the op value.

 

<my search>
| table op
|map [search op=$op$ <more search stuff> ]
...
| timechart count as Vol, values(op) as op
| predict Vol

 


When doing this I get a table with multiple times, once for each op like the below:

_timeVolophigh(prediction(Vol))low(prediction(Vol))
12:0010test1127
12:0011test2148
12:1515test11711
12:1512test21510
12:30(predicted time)  1610
12:30(predicted time)  129

 

Any ideas why this is no populating?

Labels (1)
0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

Try

| timechart count as Vol by op
0 Karma

aohls
Contributor

This errors out, predict can't be used if the timechart has a split by.  I have used map work around this and pass in the op, run the predict for each oue and get the data. With the output though there is no way to tell what belongs to what op.

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

A Four-Part Event Series: Full Stack Observability For the AI Era

As AI reshapes applications, infrastructure, and the way teams operate, the traditional boundaries of ...

SOC4Kafka - New Kafka Connector Powered by OpenTelemetry

The new SOC4Kafka connector, built on OpenTelemetry, enables the collection of Kafka messages and forwards ...

Event Series: Level up your SOC: Advancing with Splunk Enterprise Security

AI has fundamentally raised the stakes for security operations, and this three-part series is your guide to ...