Splunk Search

For loop on each result of a the table

giolapid911
New Member

I have query that  returns successful logins and a profile ID.

 

Then from the result of those I want to create another search for each result that shows the email address of the the profile ID.

 

First query is 

index=commerce loginSuccessful=true
| stats count by profile

giolapid911_0-1667594223270.png

 

Then I would want to do the following.

 

For each "profile"

index=commerce "profile email!="<null>" email!=null | table profile email 

 

Labels (1)
0 Karma

johnhuang
Motivator
index=commerce ((loginSuccessful=true) OR ("profile email!="<null>" AND email!=null))
| eval login_ct=CASE(loginSuccessful="true", 1)
| stats sum(login_ct) AS login_ct BY profile email
0 Karma
Get Updates on the Splunk Community!

Splunk + ThousandEyes: Correlate frontend, app, and network data to troubleshoot ...

 Are you tired of troubleshooting delays caused by siloed frontend, application, and network data? We've got a ...

Splunk Observability for AI

Don’t miss out on an exciting Tech Talk on Splunk Observability for AI!Discover how Splunk’s agentic AI ...

🔐 Trust at Every Hop: How mTLS in Splunk Enterprise 10.0 Makes Security Simpler

From Idea to Implementation: Why Splunk Built mTLS into Splunk Enterprise 10.0  mTLS wasn’t just a checkbox ...