cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
taramoe
Advocate II
Advocate II

Send email based on SharePoint person field

I have a SharePoint list with a bunch of columns along with a person/group field.  Each Monday I'd like all the records based on a specific filter to be gathered and sent to those names in the person/group field.  Example of my SharePoint list:

 

Project Name               Date                           Person

ProjectXYZ                   10/7/2019                  Sam Jones

ProjectABC                   10/7/2019                  Jack Johnson

ProjectEFG                    10/7/2019                 Sam Jones

 

The result I'm looking for is one of the two below, either would work.

Option 1: I want one email sent to Sam Jones with his two records and one email sent to Jack Johnson with his one record.

Option 2: I would like one email sent to both of them with the complete list of all three projects.

 

I'm getting stuck. When I put the Email field from my SharePoint list in the 'To' line, I get two duplicate emails.  What am I missing?

Below are my screen shots:

Slide Reminder Whole Flow.jpgSlide Reminder Get Items.jpgSlide Reminder Send Email.jpg

2 REPLIES 2
abm
Super User
Super User

Hi @taramoe 

 

You need to get the distinct (unique) from Person column.

 

Have a look at this link

 

https://powerusers.microsoft.com/t5/Flow-Cookbook/How-to-get-unique-column-values-from-a-SharePoint-...

 

Once you got the distinct values use the GetItems to filter by each person collect all values in an array or something. Finally send email. Here you need to use two for each loop. One for distinct values and another for get items.

 

Hope it make sense.

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up.

 

Thanks

 

 

 

 



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blog
Power Automate Video Tutorials

Hi @abm , thanks for your reply.  There are two issues here. 

 

1) After reviewing the link you sent, I inserted the Select and Set variable steps.  My Select box doesn't look like the one in the example and I don't have an option to set the variable, it's blank.

Slide Reminder Select & Set Variable.jpg

2) I don't necessarily understand the complete flow process to put it all together.  Even if I could get the distinct piece to work, how do I build the rest of it so it loops through correctly?

 

 

 

 

 

 

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (3,174)