web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Checking if a record f...
Power Automate
Answered

Checking if a record from one SharePoint list exists on another list

(0) ShareShare
ReportReport
Posted on by 8

Hi Power Community, 

 

I'm having an issue automating a flow, which checks for matching records across 2 SharePoint lists and then emails those not found within the second list.

 

List A contains a name, site and email

List B contains a name and site and date

 

The outcome of this flow is the following steps: 

  • Once a month
  • Get items from the List A
  • Get item from the List B
  • If a record from List A, matches the record in List B for the current month do nothing
  • If a record from List A does not match in List B send an email to the corresponding email from List A

 

I have found away to produce the flow but the issue is that it loops through both lists and sending me around 100 emails. 

 

nlrd56_1-1663768429076.png
nlrd56_2-1663768465405.png

 

nlrd56_3-1663768507075.png

 

Categories:
I have the same question (0)
  • Verified answer
    v-liwei-msft Profile Picture
    Microsoft Employee on at

    Hi @nlrd56 

     

    The two apply to each nesting is what causes the mail to be sent multiple times. 

    I suggest you to use only one apply to each (sending emails need to use the email address column in listA so just put ListA in apply to each) 

    Use the fliter array in apply to each (filter listB). 

    Add a condition and use the length function to determine the result of the filter. 

    If the result of length is greater than 0, the item is proved to match, if it is equal to 0, it is proved not to match.

     

    I have made a test for your reference:

    vliweimsft_0-1663828226434.jpeg

     

    Best Regards,

    Levi

     

  • nlrd56 Profile Picture
    8 on at

    Hi Levi, 

     

    I tested this and didn't receive any emails. In my flow I have 2 conditions which are checked so it doesn't work with filtering the array once. Is there a way I can filter this against the two conditions?

     

    Just so I'm clear.

    - For each record in List A

    - Filter List B by 2 conditions

    - If the length from the filter is equal to 0, this means the record doesn't match

    - Send email

     

    Would that be correct?

  • v-liwei-msft Profile Picture
    Microsoft Employee on at

    Hi @nlrd56 

     

    You can use expressions in advanced mode of filter array, which allows you to use multiple conditions.

    vliweimsft_0-1663897229209.jpeg

    I think will help you a lot:

    Power Automate Filter Array + Examples - EnjoySharePoint

     

    Best Regards,

    Levi

     

  • nlrd56 Profile Picture
    8 on at

    @v-liwei-msft Thanks for your help. 

     

    I've been through the link suggested but it only shows for filtering an array not for a sharepoint array so using that didn't work. It seems like it should be simple enough but unfortunately still unsolved. 

     

     

  • nlrd56 Profile Picture
    8 on at

    With a few minor changes I was able to get this working perfectly. Thanks for your help. I will post the solution. 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Valantis Profile Picture

Valantis 711

#2
Vish WR Profile Picture

Vish WR 691

#3
Haque Profile Picture

Haque 525

Last 30 days Overall leaderboard