Hello everyone,
I would like to ask you for an assistance if possible. Is there a way how to rename an attachment when used a sendemail command within MAP (loop)?
Below simple command sends out two emails, however each attachment matches this naming convention = unknown-YYYY-MM-DD.
############ START OF SAMPLE SEARCH ###############
| makeresults format=csv data="name,age
Robert,18
Filip,22
"
| map maxsearches=2 search="search index=_internal $name$| stats c
| sendemail
to=\"robert@destination.com\"
subject=\"Splunk report\"
message=\"See attached report.\"
sendresults=true
format=csv"
############### END OF SAMPLE SEARCH ###############
Hi @Kopcisko
Unfortunately you can only set the filename when triggering from a alert action or from a scheduled search.
🌟 Did this answer help you? If so, please consider:
Your feedback encourages the volunteers in this community to continue contributing