Getting Data In

How to pick only non comma (",") related events and show in table?

akshayinnamuri
Loves-to-Learn Lots

Hi have a results from my mail index

say log look like below

sender=abc recipient=xyz@sample.com,ghi@nonsample.com country=abc

sender=def recipient=team@nonsample.com country=xyz

sender=gfh recipient=tip@nonsample.com country=efg

sender=abc recipient=none@sample.com,sample@nonsample.com country=pqr

I want to shows in a table only the non comma separated recipients only (as highlighted in bold where there are no multiple recipients)

 

can some one help me on this

 

Labels (2)
Tags (1)
0 Karma

akshayinnamuri
Loves-to-Learn Lots

Thanks all,
above didnt work..
however I tried 
| eval recipient=split(recipient,","), rec_count=mvcount(rcpt)
| where rec_count=1
|table ...

 

and got the result

0 Karma

scelikok
SplunkTrust
SplunkTrust

Hi @akshayinnamuri,

You can simply filter them by using below;

| search NOT sender=*,*
If this reply helps you an upvote and "Accept as Solution" is appreciated.
0 Karma

ITWhisperer
SplunkTrust
SplunkTrust

I think @scelikok meant

| search NOT recipient=*,*
0 Karma

scelikok
SplunkTrust
SplunkTrust

Yes @ITWhisperer , thank you for correction

If this reply helps you an upvote and "Accept as Solution" is appreciated.
0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.
Get Updates on the Splunk Community!

Introduction to Splunk AI

How are you using AI in Splunk? Whether you see AI as a threat or opportunity, AI is here to stay. Lucky for ...

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 ...

Maximizing the Value of Splunk ES 8.x

Splunk Enterprise Security (ES) continues to be a leader in the Gartner Magic Quadrant, reflecting its pivotal ...