I have a search query like this
index=ppt sm.to{}="[email protected]" OR sm.to{}="[email protected]" |table sm.to{} sm.stat
and I want to use a csv lookup instead because I have more email address to use and I want the result to show this two fields .
My csv contains this
sm.to{}
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
Can anyone help with a lookup search query for me . thanks.
Try this:
index=ppt | lookup .csv sm.to{} OUTPUT sm.to{} as sm_to | search sm_to = *
Try this:
index=ppt | lookup .csv sm.to{} OUTPUT sm.to{} as sm_to | search sm_to = *
am actaully using inputlookup so i used the below command but it did not work
index=proofpoint sourcetype=pps_maillog | inputlookup smto OUTPUT sm.to{} as sm_to | search sm_to = *
I tried the following as well but did not work
index=ppt
| eval Recipients='sm.to{}'
| table Recipients
| search Recipients = "*"
| join type=inner Recipients
[| inputlookup smto
| table sm.to{} sm.stat]
Thanks @manjunathmeti it worked perfectly.
index=ppt | lookup .csv sm.to{} OUTPUT sm.to{} as sm_to | search sm_to = * | table sm_to sm.stat
May be it's due to field name, rename sm.to{} to smto in csv file and search query and try.