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!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...