Skip to main content

Notifications

Community site session details
Power Apps - Building Power Apps
Answered

Distinct function for combobox is populating blanks

Like (0) ShareShare
ReportReport
Posted on 24 Jan 2021 10:53:46 by 30

Hey guys, im trying to do a simple thing - I have a SP List in which the "Title" column have some duplicate values.
In my app, i would like to populate a combobox with all the UNIQUE "Title" values using the Distinct function, but when im doing it, im getting only blanks:

Barak_S_1-1611485537632.png

Barak_S_2-1611485555662.png

Barak_S_3-1611485566789.png



Any idea why and how can i fix this?

**BTW the "Title" column is text.

 

Thanks

  • Pstork1 Profile Picture
    66,079 Most Valuable Professional on 12 Jul 2024 at 18:48:52
    Re: Distinct function in combobox is populating blanks

    Please post this as a new question.  You'll get more responses and others will be able to find the answer more easily later.

  • GREGWOUARE Profile Picture
    39 on 12 Jul 2024 at 08:59:29
    Re: Distinct function in combobox is populating blanks

    Hi mate,

     

    I currently the same problem as you faced back in 2021. I'm working in power apps for teams, trying to distinct value from a SP list, choice column, in a combobox

     

    I have normaly 4 Distinct value comming from my choice column, but only the first one is populated

     

    GREGWOUARE_0-1720774727455.png

     

    I also tried the formula of @Pstork1 , but still, only one value is populated

     

    do you have any other advice ? thanks

     

     

  • jms0529 Profile Picture
    36 on 31 Jul 2023 at 17:11:54
    Re: Distinct function for combobox is populating blanks

    @RWO - Adding the value field solved my issue with the blank results when using the Distinct Function. Thank you. Two days of banging my head against a wall until finding this!!!

  • Krishna09 Profile Picture
    234 on 26 Aug 2022 at 14:12:30
    Re: Distinct function for combobox is populating blanks

    I have changed text data type to combobox in form and tried above formulae for values from table1. Now, I am trying to submit these values to table2. when I changed the defaultselecteditems = parent.default. I am receiving below error. what items I have to change, If I want to save this data to table2

    Krishna09_0-1661523424403.png

     

  • comandante2 Profile Picture
    11 on 26 Aug 2022 at 12:51:24
    Re: Distinct function for combobox is populating blanks

    Krishna 09,

    you should always use double quotes when dealing with text. Single quotes won't work.

     

  • Krishna09 Profile Picture
    234 on 26 Aug 2022 at 12:48:25
    Re: Distinct function for combobox is populating blanks

    It worked. I used single cots(''), it didn't work but when double cots (" ") It worked. what is the reason?

  • comandante2 Profile Picture
    11 on 26 Aug 2022 at 12:43:00
    Re: Distinct function for combobox is populating blanks

    Hi, Krishna09

    You should change your formula to the following: Sort(Distinct(test1,title & " " & 'Name'),Result)

    This & " " & means a space between your title and Name. You can change it to "-" or any other symbol you wish

     

  • Krishna09 Profile Picture
    234 on 26 Aug 2022 at 12:29:21
    Re: Distinct function for combobox is populating blanks

    I used below formulae to a comb box, to get combination of two columns distinct values. below formulae worked.

    Sort(Distinct(test1,title & 'Name'),Result)

    But, I wanted it to be separated by'-' or any other character. because Tittle and Name  values are shown without space between them. Someone please help me with this.

  • JavSan Profile Picture
    3 on 10 Jun 2022 at 21:53:31
    Re: Distinct function for combobox is populating blanks

    Nice Job Warren, every now and then I come across one of your anwers and they never fail me, thanks Sir.

  • comandante2 Profile Picture
    11 on 01 Jun 2022 at 14:14:53
    Re: Distinct function in combobox is populating blanks

    Thanks for this advice! It fixed my problem

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

#1
WarrenBelz Profile Picture

WarrenBelz 146,743 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,079 Most Valuable Professional

Leaderboard
Loading started
Loading started