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 Apps / Distinct formula doesn...
Power Apps
Answered

Distinct formula doesn't work on collection

(0) ShareShare
ReportReport
Posted on by 40

Hello!

 

The data source is a table in Oracle Database with columns xxx, yyy, name. The number of rows around 4000 and has 9 distinct NAME values. All of the columns have VARCHAR2 format.
I use the solution there you create a bunch of collections and create one mega-collection out of it.

How I do it:

On Visible I set -

Concurrent(
ClearCollect(Digital, Filter('[S].[D_ORG]', NAME = "Digital Services")),
ClearCollect(Group, Filter('[S].[D_ORG]', NAME = "Group Management")),
ClearCollect(CX, Filter('[S].[D_ORG]',NAME = "Customer Experience"))
)
;
ClearCollect(AllStructure, Digital, Group, CX)

Seems like I get the data I needed, but if I use distinct on my mega-collection I get an error "Expected 2, recieved 1". I checked the data again and I have several values in the column I use.

Any ideas?

Categories:
  • mdevaney Profile Picture
    29,993 Moderator on at

    @bonifacious 

    Where is your DISTINCT formula?  That is what caused the problem but I cannot see it in the code you supplied.

     

    Distinct needs 2 arguments

    Distinct(your_table_name, your_column_name)

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up." 

  • bonifacious Profile Picture
    40 on at

    Hey, @mdevaney !

     

    Basically after I create mega-colelction AllStructure I want to use the formula Distinct([@Allstructure].NAME) for a dropbox

     

  • Verified answer
    mdevaney Profile Picture
    29,993 Moderator on at

    @bonifacious 

    Its a syntax error.  The table name and column name must be separated by a comma, not a dot.

    Distinct([@Allstructure], NAME) 

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

  • bonifacious Profile Picture
    40 on at

    Oh my, I am missing the simple stuff.

    Thank you so much, @mdevaney !

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 395 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 328

#3
WarrenBelz Profile Picture

WarrenBelz 260 Most Valuable Professional

Last 30 days Overall leaderboard