Splunk Search

1. I am new at splunk and would like to know how to search two separate months in the same search syntax? 2. I would also like to know how to put 2 searches in one search.

GHOST27
Engager

Starting with this:

index=* smtp sourcetype="""""""" email="*" date_month=june

I tried date_month=may AND june and it did not work. I need this:

index=* smtp sourcetype="""""""" email="*" date_month=may 
| table _time sourcetype email src det count src_tags 
| stats count by _time sourcetype src det email  

And:

index=* smtp sourcetype="""""""" email="*" date_month=june 
| table _time sourcetype email src det count src_tags 
| stats count by _time sourcetype src det email

Do I use a I use the join command? Can you provide an example.

Tags (2)
0 Karma
1 Solution

cmerriman
Super Champion

can you try this:

index= smtp sourcetype="""""""" email="" (date_month=may OR date_month=june )
| stats count by _time sourcetype src det email 

View solution in original post

cmerriman
Super Champion

can you try this:

index= smtp sourcetype="""""""" email="" (date_month=may OR date_month=june )
| stats count by _time sourcetype src det email 
Get Updates on the Splunk Community!

Announcing Scheduled Export GA for Dashboard Studio

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

Extending Observability Content to Splunk Cloud

Watch Now!   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to leverage ...

More Control Over Your Monitoring Costs with Archived Metrics GA in US-AWS!

What if there was a way you could keep all the metrics data you need while saving on storage costs?This is now ...