This blog post is going to win an award for best title ever. 🙂
A colleague and I were working on a problem where we wanted to aggregate all the list items that were assigned to a particular person, and then send them an aggregated e-mail in a simple HTML table. Sounds easy enough right?
To get started – let’s create a simple list with Title, Owner (Person), and DueDate (Date/Time) columns like below:
Next, we’re going to create our Flow from a Blank Template and have the Trigger be Flow Button for mobile – essentially manual for testing purposes. Next, add the “Get items” action and enter your site address & list name:”
Before we add the filter to Get items, I recommend you save and test the flow so that you can see what gets returned from SharePoint before you apply your filter.
What gets returned is in the Body section of the Get items outputs:
Looking at what’s returned you’ll see that the Owner column has properties such as Claims, DisplayName, and Email.
Now, let’s go ahead and add the filter so that we’ll return List items that have email@example.com as the Owner.
Show advanced options to show the Filter Query input
Now let’s add the filter and notice the case sensitivity. You’ll want to reference the e-mail attribute as ColumnName/EMail so for my example it’s Owner/EMail
Now try running your Flow and you should see success!
The output of the Get Items is now a collection of all the Items returned based on your filter. Now you can loop through the results and take the appropriate action based on your use case.