Skip to main content

Notifications

Community site session details

Community site session details

Session Id : SaBNS0a7m3WQqAHKFBqneu
Power Apps - Building Power Apps
Unanswered

Lookup Dropdown Duplicates: Solution Required for Power Apps Form

Like (2) ShareShare
ReportReport
Posted on 1 Oct 2024 17:15:13 by 9
Hi everyone,
 
I'm having trouble with duplicate values appearing in lookup dropdowns in my Power Apps form.
 
I have a main SharePoint list ("ABCD") with 10 text question columns and 3 lookup columns (Department, Country, R-Level). These lookups pull from a separate SharePoint list called "Approvers".
 
The "Approvers" list structure causes my issue. It contains multiple entries for the same country based on different Department/R-Level combinations (e.g., Department P > Country India > R-Level Red, Department P > Country India > R-Level Amber). This duplication results in redundant values within my Power Apps form's lookup dropdowns for Department, Country, and R-Level.
 
How can I configure these dropdowns to display only unique values for each field, while still ensuring the selected values correctly update the corresponding columns in my main SharePoint list? This is crucial as a Power Automate flow relies on these fields to route approvals.
 
Attached are screenshots of the "Approvers" list structure and the duplicate values displayed in the Power Apps form. Any help would be greatly appreciated!

 
Categories:
  • CU01101712-0 Profile Picture
    9 on 02 Oct 2024 at 04:42:03
    Lookup Dropdown Duplicates: Solution Required for Power Apps Form
    Hello @FL Mike,
     
    This code works perflectly fine(Screenshot below),  How can i add distinct to this code? I've tried all AI Chatbots and none have given me the correct way to make this work with disctinct. 
     
  • Michael E. Gernaey Profile Picture
    42,027 Super User 2025 Season 1 on 01 Oct 2024 at 18:14:07
    Lookup Dropdown Duplicates: Solution Required for Power Apps Form
    Hi
     
    You need to use the Distinct Function
     
    for instance Distinct(MyList, Country)
     
    Where Country is the Field/Column Name so change it as you need it.
     
    Understand though, that you could also union the list to itself, which would remove the duplicates.
     
    One thing to note, when you do this, then your Dropdowns do NOT point to a record, they point to the "string" you are doing the Distinct on, unless its a LooKup etc, in which case thats different.
     

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Apps - Building Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 89 Most Valuable Professional

#2
MS.Ragavendar Profile Picture

MS.Ragavendar 60

#3
stampcoin Profile Picture

stampcoin 48

Overall leaderboard
Loading started