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

Community site session details

Session Id : rI4FVcwNdEN69BiwmVDBNR
Power Apps - Building Power Apps
Answered

Display Unique Values in Gallery

Like (0) ShareShare
ReportReport
Posted on 28 May 2023 08:48:27 by 39

Hello!

I am trying to display the order numbers in the gallery title. I was able to do it using distinct in the Text property.

 

Distinct('Promotion - Order Table', OrderID)

 

However, I also want to access the dates associated with the OrderID and display it as well as the orderID subtitle. If i use distinct, I can only access the OrderIDs. If i use Groupby, i experience the same problem, I can only access the collection name and its values which are the orderIDs. 

 

Please help. 

 

Thank you!

Categories:
  • marctimothy Profile Picture
    39 on 28 May 2023 at 09:21:59
    Re: Display Unique Values in Gallery

    Hi! Thank you to the both of you! The solutions worked! Been looking for these answers for hours! 

  • Verified answer
    WarrenBelz Profile Picture
    148,894 Most Valuable Professional on 28 May 2023 at 09:16:14
    Re: Display Unique Values in Gallery

    Hi @marctimothy ,

    Try this

    AddColumns(
     GroupBy(
     'Promotion - Order Table', 
     "OrderID",
     "Data"
     ),
     "OrderDate",
     First(Data).'Order Date'
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

  • Verified answer
    cha_cha Profile Picture
    4,932 Moderator on 28 May 2023 at 09:14:00
    Re: Display Unique Values in Gallery

    Hello @marctimothy 

     

    PowerApps can identify distinct records and you can use a combination of ForAll, Distinct and AddColumns function.

    ForAll(
     Distinct(
     AddColumns('Promotion - Order Table', "IDDate",
     {
     OrderID: OrderID,
     DateColumnName: DateColumnName
     }
     )
     , IDDate),
     ThisRecord.Value
    )

     

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 791 Most Valuable Professional

#2
MS.Ragavendar Profile Picture

MS.Ragavendar 410 Super User 2025 Season 2

#3
mmbr1606 Profile Picture

mmbr1606 275 Super User 2025 Season 2