cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
irsimeonov1
Level: Power Up

Can a wildcard be used to indicate 'all items' in a Filter function?

Hi

 

I am trying to understand whether I can somehow replicate Excel's * in a filter function so that the function returns all items in a table. For example Filter(TableName, Column1 = "*"), what do I need to put instead of the * so that the function returns all of the records in TableName?

 

Thanks

3 REPLIES 3
PowerApps Staff carlosag
PowerApps Staff

Re: Can a wildcard be used to indicate 'all items' in a Filter function?

There is no wildcard as such, but there are a few ways you could achieve that by for example using an "If" and return either the full datasource or a filter expression, or you can use an "Or" to check if it should return all of the rows, here is what I do:

 

	Filter(UserMessages, Email = Dropdown1.Selected.Value || Dropdown1.Selected.Result = "<All>" )

 

irsimeonov
Level: Powered On

Re: Can a wildcard be used to indicate 'all items' in a Filter function?

Thanks, that is a nice way to do it Smiley Happy

Highlighted
Charles_John
Level: Powered On

Re: Can a wildcard be used to indicate 'all items' in a Filter function?

This is old, but there is not a whole lot of documentation and help for PowerApps so i'm adding where i can.

 

I don't understand the "<All>" syntax of the accepted solution, so this is what I did:

 

Filter(
TargetTable,
If(
DropDown1.Selected.Value <> "[YourDefaultValue]",
DropDown1.Selected.Value = TableFilterColumn1,
TableFilterColumn1 in DropDown1Selections
),
If(DropDown2.Selected.Value <> "[YourDefaultValue]",
DropDown2.Selected.Value = TableFilterColumn2,
TableFilterColumn2 in DropDown2Selections
),
...
)

 

And you can continue the logic for how every many dropdown filters you want to use. Each dropdown when not equal to the first/default value will act as an AND filter for the returned table, which I use as the Items property of a gallery.

 

Be sure to set DropDown1 Items property = DropDown1Selections and DropDown2 Items property = DropDown2Selections. I Collect the two collections with a button.

 

Helpful resources

Announcements
firstImage

PowerApps Monthly Community Call!

Join us next Wednesday for our Demo Extravaganza, October 16, 2019 8am PDT.

firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

SecondImage

Power Platform Summit North America

Register by September 5 to save $200

Top Kudoed Authors
Users Online
Currently online: 393 members 4,807 guests
Recent signins:
Please welcome our newest community members: