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

Filtering - allowing multiple values from same column

Hi 

 

I would like to filter a gallery to show items if either of results are in the datasource

 

My forumla is below:

 

SortByColumns(Filter(iPadBooking,DateRequired = TextInput1.Text, Delivered="Delivered"),"TimeRequired",Ascending)

 

I would also like to show items where Delivered="Pending" in the same gallery at the same time

 

How would I acheive this?

 

Thanks

2 REPLIES 2
Highlighted
Super User
Super User

Re: Filtering - allowing multiple values from same column

Hi @SChappell2580

 

You can do this by combining the use of the And and Or functions.

 

The syntax would look something like this:

 

SortByColumns(
  Filter(iPadBooking, 
         Or(And(DateRequired = TextInput1.Text, Delivered="Delivered"),
            Delivered="Pending")
  ),
  "TimeRequired",Ascending
)

 

Highlighted
Frequent Visitor

Re: Filtering - allowing multiple values from same column

Hi,

The below code will work,

 

SortByColumns(Filter(iPadBooking,DateRequired = TextInput1.Text,(Delivered="Delivered"||Delivered="Pending")),"TimeRequired",Ascending)

Helpful resources

Announcements
secondImage

New Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (8,251)