Splunk Search

How to pull a value from one column based on condition on another column?

infoneo
New Member

I am trying to run an equivalent of the below query in splunk search, please help.

SELECT CONCAT(run, '.', tag) as file_name,time_at as end_time FROM log WHERE message = 'processing' and msg_type = 'COMPLETE' order by id desc

index=history source=mysql-pipe sourcetype=pipeline_logs|eval file_name=run_name.".".tag |eventstats time_at as start_time where like(message,"processing") AND like(message,"COMPLETE") |table file_name start_time

Tags (1)
0 Karma

richgalloway
SplunkTrust
SplunkTrust

Looks like there's a typo in your question. like(message, "COMPLETE") likely should be like(msg_type,"COMPLETE").

---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Join Us for Splunk University and Get Your Bootcamp Game On!

If you know, you know! Splunk University is the vibe this summer so register today for bootcamps galore ...

.conf24 | Learning Tracks for Security, Observability, Platform, and Developers!

.conf24 is taking place at The Venetian in Las Vegas from June 11 - 14. Continue reading to learn about the ...

Announcing Scheduled Export GA for Dashboard Studio

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