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 / Filter gallery based o...
Power Apps
Unanswered

Filter gallery based on choice field in list not working

(0) ShareShare
ReportReport
Posted on by 21

I am trying to filter a gallery based on a drop down.  The table is Product_Enhancement_Requests, the column for fitlering is named Product_x0020_Area, the dropdown is named dropdown1 and items in the dropdown are set to ["Admin", "Alerts", "Benchmark"].  In the Gallery the Items is set to: 

 

Filter(Product_Enhancement_Requests,Dropdown1.Selected.Value in "Product_x0020_Area")

 

There is no syntax error so I believe the syntax is correct.

 

However, the gallery gives no results for any of the options selected in the drop down.  There are records with these values in the table (in a SharePoint List).

 

I have also tried using the following filter syntax but these didn't work either:

 

Filter([@Product_Enhancement_Requests],Dropdown1.Selected.Value in "Product_x0020_Area")

Filter([@Product_Enhancement_Requests],"Product_x0020_Area"=Dropdown1.Selected.Value)

Filter(Product_Enhancement_Requests,"Product_x0020_Area"=Dropdown1.Selected.Value)

 

This seems like it should be a very simple filter statement but I cannot get it to work.  Please help.

Categories:
I have the same question (0)
  • Meneghino Profile Picture
    6,949 on at

    Try this:

     

    Filter(Product_Enhancement_Requests, Product_x0020_Area = Dropdown1.Selected.Value)

    (No need for quotes to wrap the column name)

  • Tblok Profile Picture
    21 on at

    Thanks Tried:

    Filter(Product_Enhancement_Requests, Product_x0020_Area = Dropdown1.Selected.Value)

    and received an 'Invalid arguement type' 

  • Tblok Profile Picture
    21 on at

    Seems to be an issue with filtering on a Choice type in List fields.  When I use a field that is a text data type it works.  Shouldn't Filter work independent of the column type?

  • Meneghino Profile Picture
    6,949 on at

    Ah, choice type field.  I know that there were initial issues with this type of field in SharePoint.  I am frankly not sure what the current status is on support for this type of field in PowerApps.  There are a number of other threads on this.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    When you stick it in an if statement it seems to work, you can set your Gallery Items to: 

    If(Dropdown1.Selected.Value = "Admin", Filter(Product_Enhancement_Requests, Product_x0020_Area.Value = "Admin"),
    Dropdown1.Selected.Value = "Alerts", Filter(Product_Enhancement_Requests, Product_x0020_Area.Value = "Alerts"),
    Dropdown1.Selected.Value = "Benchmark", Filter(Product_Enhancement_Requests, Product_x0020_Area.Value = "Benchmark"), Product_Enhancement_Requests)

    This is assuming your Dropdown1 items is 

    ["Admin","Alerts","Benchmark","all"]

    *edit: Not tested with choice items did not read that bit yet 😞

     

    Seems to work if on your choice fields you make sure to use value, so Product_x0020_Area.Value

  • Tblok Profile Picture
    21 on at

    Thanks, appreciate the suggestion.  That was the start of my dropdown list for testing.  There are actually going to be more than that so the If statements would be rather length and would end up requiring maintenance if options change.  I will keep this in mind for another field I have where the options are much more limited and less likely to change.

  • hgowdy Profile Picture
    84 on at

    Had similer issue. Added additional SP list column set as "single line of text" that used caculated field = to selected drop down value and then filted on that new field.

  • OlinMeeks Profile Picture
    16 on at

    hgowdy: This worked for me too when I had a similar problem. "Added additional SharePoint list column set as "single line of text" that used calculated filed = selected drop down value (choice field) and then filtered on that new field."

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    This didn't work for me - I still get the service limitations blue dot.

     

    I'm simply filtering for X=optionset1 and understand that powerapps only supports sharepoint single item lists but creating a new calculated field and setting it equal to the option set doesnt seem to work.

  • OlinMeeks Profile Picture
    16 on at

    I believe the blue dot is a suggestion (not an error) and is regarding to delegation.  Read the article on delegation (https://powerapps.microsoft.com/en-us/tutorials/delegation-overview/) and you will see what the blut dots are.  In summary, I believe it is reminding you that if your list/source has more than 500 items then PowerApps will only process 500 items at a time (so the whole of the line items will not appear in your gallery if it is over 500 items).  You could potentially off-load some of your list items into a separate list built using a flow query to bring the count down to inside of 500 - then build the gallery against the new, smaller sub-set list.  I am having to do this on project I am working on now.  I am not sure it will work but we will see.

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 June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 326 Most Valuable Professional

#2
11manish Profile Picture

11manish 168

#3
sannavajjala87 Profile Picture

sannavajjala87 75 Super User 2026 Season 1

Last 30 days Overall leaderboard