Splunk Search

How to Identify the events based on condition on other events

rangarbus
Path Finder

Hello Splunk Experts: From a system, we receive following events in splunk.

I would like to get the event which doesn't have logEvent as Received but has only logEvent as Delivered.

traceId field will have same value on both Received and Delivered events.

Here in the below example, traceId=101 is such an event.  

 

{"logEvent":"Received","traceId": "100","message":"Inbound received", "id" : "00991"}
{"logEvent":"Delivered","traceId": "100","message":"Inbound sent", "id" : "00991-0"}
{"logEvent":"Delivered","traceId": "101","message":"Inbound sent", "id" : "00992-0"}
{"logEvent":"Received","traceId": "102","message":"Inbound received","id" : "00993"}
{"logEvent":"Delivered","traceId": "102","message":"Inbound sent","id" : "00993-0"}

 

 

Labels (2)
0 Karma
1 Solution

ITWhisperer
SplunkTrust
SplunkTrust

Are the fields already extracted?

| eventstats values(logEvent) as logEvents by traceId
| where logEvents="Delivered" AND mvcount(logEvents) = 1

View solution in original post

ITWhisperer
SplunkTrust
SplunkTrust

Are the fields already extracted?

| eventstats values(logEvent) as logEvents by traceId
| where logEvents="Delivered" AND mvcount(logEvents) = 1
Get Updates on the Splunk Community!

Index This | Why did the turkey cross the road?

November 2025 Edition  Hayyy Splunk Education Enthusiasts and the Eternally Curious!   We’re back with this ...

Enter the Agentic Era with Splunk AI Assistant for SPL 1.4

  🚀 Your data just got a serious AI upgrade — are you ready? Say hello to the Agentic Era with the ...

Feel the Splunk Love: Real Stories from Real Customers

Hello Splunk Community,    What’s the best part of hearing how our customers use Splunk? Easy: the positive ...