Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Unanswered

Loading Excel result into an array for faster lookup?

(0) ShareShare
ReportReport
Posted on by 127
Dataverse table has a list of clients that maybe inactive and need to be deactivated.
The list of clients that are supposed to be active is provided in an Excel table containing client IDs.
 
The flow is as follows:
 
List Rows (Dataverse) 
For each row, look up the Excel table to see if the client ID exists using Filter Query . If it doesn't then client is not in the active list and will be deactivated.
My issue is it is slow so it's possible for each row, it keeps reloading the Excel from OneDrive and does a lookup for matching client ID. If so it will be more efficient to read the Excel once and load the active client IDs in an array. Then in Apply to each, search the array for the matching client ID. But I couldn't find any reference on how to search an array for matching entry.
 
 
Categories:
  • creativeopinion Profile Picture
    10,439 Super User 2025 Season 1 on at
    Loading Excel result into an array for faster lookup?
    You are absolutely correct when you say:
    If so it will be more efficient to read the Excel once and load the active client IDs in an array. 
     
    It's always best practice to have the List Rows in a Present Table action outside of an Apply to Each loop. This way you only need to run this action once and with a Filter Array action you can filter out the item(s) that match your criteria. 
     
    To learn more about how to use the Filter Array action, please refer to this YT Tutorial: Are you using the Microsoft Power Automate Filter Array Action wrong?

    In this video tutorial I’ll show you 3 practical ways to use the Filter Array action and how to use it properly.
    1️⃣ Cross-Referencing Data
    2️⃣ Filtering by Key
    3️⃣ Substring Matching

    Did you know that the Condition action has a limit of 10 conditions? Although it might look like the Filter Array action can only accept one condition—this is not true. By using the advanced mode you can enter multiple conditions into a Filter Array action with an expression.

    IN THIS VIDEO:
    ✅ 3 Ways to Use the Filter Array Action
    ✅ How to use the Scope Action to Group Actions
    ✅ How to Check the Number of Items returned from a Filter Array Action
    ✅ How to Cross-Reference Data in Excel with a SharePoint List
    ✅ How the Filter Array Action Works
    ✅ How to Access the Dynamic Content from a Filter Array Action
    ✅ How to Filter Items by a Key
    ✅ How to Filter Items by Matching a Substring
    ✅ How to Use Multiple Conditions in a Filter Array Action
     
     
    Hope this helps!

    Consider giving me a ❤️ if you liked my response!

    👉 Level up your Power Automate skills by checking out my tutorials on YouTube
    👉 Tips and Tricks on TikTok and Instagram

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

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard >