cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PVosEska
Resolver IV
Resolver IV

Filter dropdown on combination of columns

Hello Y'all,

 

I have a SP list with 2 columns

Available Dates

Available Times

 

i build an app where these dates are normal dropdown values, instead of dates.

i want to filter the 'Available Times' in the 'Available Dates' and only give back when there is no combination of that date and time existing in the list.

 

For example,

 

if i choose the 1st of december, and there already have a row that has that date, with the time 09:00, i want this time to NOT show up in the dropdown.

 

Endgoal: 

 

Have every row be unique, so we have one date and one time per row.

 

Hope you can help, thanks!

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @PVosEska ,

 

Thanks, please try this:

Filter(Choices(Interviews. 'Available Times'), !(Value in Filter(Interviews, DateCombobox.Selected.Value in 'Available Dates'.Value).'Available Times'.Value))

 Best regards,

Sik

View solution in original post

3 REPLIES 3
v-siky-msft
Community Support
Community Support

Hi @PVosEska ,

 

What are the date types of these two columns? What are the items properties of drop-down controls? Can you share some screenshots with your apps?

 

You can refer to this formulas, It doesn't mean this formulas is absolutely right, the exact expression needs more details you need to post. However you can get some reference. 

Filter(<Items of Times drop down>, !(<Field of Times drop down> in Filter('SP list',  DateDropDown.Selected.Value in 'Available Dates').'Available Times'))

The table which needs to be filtered should be Items of dropdown, and logical test statment is to filter out the SP list items first that contains Date drop down selected date, then judge and get all Time dropdown items, that is not in just filtered SP list items.

Hope this can help.

Best regards,

Sik

If my post is helpful for you, please click on “Accept as Solution” to help other members find it more quickly.

 

Sorry, i thought i gave most of the details

 

they are 2 simple choice columns

In PowerApps, they are comboboxes.

 

The formula's for the items are 

 

Choices(Interviews.Available Dates)
Choices(Interviews.Available Times)

 

 

I'm not using forms or anything, just individual boxes.

 

I added the pictures as an attachment.

Hi @PVosEska ,

 

Thanks, please try this:

Filter(Choices(Interviews. 'Available Times'), !(Value in Filter(Interviews, DateCombobox.Selected.Value in 'Available Dates'.Value).'Available Times'.Value))

 Best regards,

Sik

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

PA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

This training provides practical hands-on experience in creating Power Apps solutions in a full-day of instructor-led App creation workshop.

PA.JPG

New Release Planning Portal (Preview)

Check out our new release planning portal, an interactive way to plan and prepare for upcoming features in Power Platform.

Top Solution Authors
Users online (2,303)