Hi,
I am using the SharePoint OOTB Task List for one of the implementations where I have Task name, description, due date(renamed to completion date), assigned to (renamed to Resposible Party), below is a screenshot for same.
I want to create a flow that runs every day at 8 am, runs and gets tasks from this list for which due date is today so i guess that would be by get items action. Now as you see in the screenshot attached, considering todays' date, below would be fetched from SharePoint as a result of get items action.
Then I would like to send an email out to Maddie and Robert letting them know that 'You have a task due please check sharepoint'.
However, if I add send an email, both maddie and robert would receive two emails each. So post get items, I would like to store distinct emails in a variable and then use that in send an email action so they only receive one email each.
Email body is pretty simple "You have a task due today, please chec in sharepoint" so nothing dyanmic as far as email body is concerned. Can someone please help me getting distinct emails for responsible party using variable or something and eventually using it in send an email.
Thanks in advance.
flow seems to work for me but it gives time out error for my SharePoint list.
I was able to get this to work, turned out that variables and apply to each are your best friends when it comes to flow ๐, please see screenshots below of the flow, hope it helps someone!
Hi @Anonymous,
You can create a String variable to accept the Email, convert Email array into a plain text, for example:
After that, you can put the EmailPlain into the Email field.
Best Regards,
Community Support Team _ Lin Tu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks @RezaDorrani , I used array variable and I am able to get unique emails in array but using it in send an email is now a pain, in send an email action , I used variables('Emails') expression to send emails out but seeing below in failed action
Of course, its coming in array form so send an email is failing, any thoughts how I can fix this? Below is output of my set variable
Hi @Anonymous
You would need to use expressions to achieve most of this
I have a sample scenario in which I retrieve data from a SP list, group the data based on a category and send emails for each category
Feel free to customize the below Flow for your needs
--------------------------------------------------------------------------------
If this post helps answer your question, please click on โAccept as Solutionโ to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
Michael E. Gernaey
497
Super User 2025 Season 2
David_MA
436
Super User 2025 Season 2
Riyaz_riz11
244
Super User 2025 Season 2