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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Sharepoint List - Auto...
Power Automate
Unanswered

Sharepoint List - Auto populate Lookup column (VLOOKUP between 2 SP Lists) based on another column (using Power Automate)

(0) ShareShare
ReportReport
Posted on by 28

Hi All,

I am trying to auto populate a lookup column in a sharepoint list from another sharepoint list based on a column.

Basically a VLOOKUP.

I am not that good with PowerAutomate and have been banking my head trying to solve this problem.

I am hoping you guys will be able to help.

Requirement:

When an item is created or modified, trigger flow.

For all items created or modified, Perform a lookup for' Brand Name' in 'LostPackagesDB' list and return the 'Retailer' field matching the 'Sender' field in the 'LP_SenderLookup' list.

 

Below is what I have done till now. But something is wrong in this flow/logic.

AchalDesai_1-1636656825866.png

Procedure:

Use Trigger when Item is created or modified.

Then get items from the master list 'LostPackagesDB'.

Then use a For Each loop and get items from the lookup list 'LP_SenderLookup' with filter query to get only the matching record.

Then store the matched Retailer value in the compose activity.

Then check if the compose activity is not empty and the 'Retailer' column in the master list is empty.

Then update the current item's 'Retailer Field with the value stored in 'Compose' activity.

AchalDesai_3-1636657135706.png

Error:

1. The Apply to Each parameter for 'Apply to Each' activity is incorrect as it is running for all the items in the list rather than just the ones created or modified and applying the matched value to all records of the master list. Is there a way we can limit the apply to each activity to only the items created/modified?

2. The flow is running in an infinite loop because I am guessing the it is iterating through all the items on the master list and each item is being modified.

3. I have a value in 'Brand Name' column of the master list that has an " ' " in it's name (e.g. Victoria's Secret). This is causing the query to fail. The flow says Unable to Build query only for this value. For other values, it works, but goes into an infinity loop as mentioned above.

 

I would be grateful if you guys could help me out on this.

 

 

 

 

Categories:
I have the same question (0)

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 364 Moderator

#3
abm abm Profile Picture

abm abm 243 Most Valuable Professional

Last 30 days Overall leaderboard