cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper II
Helper II

In the Gallery Screen, after filter the datasource , a row appears multiple times in the Gallery, can I make this row appear only once in Gallery?

As the title indicates, how can this function be completed.

 

Thank You!

Dennis

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Dennis_Qiang ,

So do you mean that if you add distinct function with filter function, your gallery will disappear?
That's really stranage.

The formula should have no problem.

I also made a similar test and not met this problem neither.

7221.PNG

 

Have you choose right field for this gallery to display?
Since you set the gallery's Items to distinct function, you will only have Result column.

So you need to choose Result column to display in the gallery.

7222.PNG

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Community Support
Community Support

Hi @Dennis_Qiang ,

Do you want to display no-repeated items in gallery?

Could you tell me

1)which column do you want to be no-repeated? this field's data type?

2)how does other fields display? For example: field1:1, field2:text; field1:1, field2:text1

Display no-repeated field1, then whether do you want to display field2 to be text, text1 or not display?

I assume that you only want no-repeated field1 and it is text type.

If so, you could use Distinct function.

The Distinct function evaluates a formula across each record of a table and returns a one-column table of the results with duplicate values removed. The name of the column is Result.

 

You could set the gallery's Items like this:

Distinct(Filter(...),fieldname)
//please replace fieldname with the field that you want no-repeated value

 

Here's a doc about this function for your reference:

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-distinct

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Dennis_Qiang_0-1594964616983.png

 

Hi @v-yutliu-msft 

I have try this method. But Distinct doesn't work at Gallery screen and can not show the filter result.

If i remove "Distinct ". The Gallery screen will show but i want the item in redbox just appear only once!!

 

Do you have idea for this problem?  Please help!!

 

Dennis_Qiang_1-1594964788446.png

 

 

Hi @Dennis_Qiang ,

So do you mean that if you add distinct function with filter function, your gallery will disappear?
That's really stranage.

The formula should have no problem.

I also made a similar test and not met this problem neither.

7221.PNG

 

Have you choose right field for this gallery to display?
Since you set the gallery's Items to distinct function, you will only have Result column.

So you need to choose Result column to display in the gallery.

7222.PNG

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Users online (7,168)