I'm unable to figure out how to loop through for each row result and send an email.
The first row works correct and sends the user an email that their account is expiring within 30 days, with the below Splunk search.
I've performed a search on Google and found I need to use the map command, but I'm unable to make the below search work with the map command in different areas of the below code.
To recap I'm downloading all the Active Directory users to a lookup table every night with their account details. I now have the lookup table and want to email users when their account is 30 days from expiring. I can only get the first result from my search to work and unable to perform the same function on each row.