cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
VineethKN
Level: Powered On

Multiple filters on 2 lists

Hi All,

i have 2 dropdowns, which i need to check if the selected values are equal and based on that populate the 3rd dropdown, also have another level of filter on this 3rd dropdown, how can i achive this

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support Team
Community Support Team

Re: Multiple filters on 2 lists

Hi @VineethKN ,

Based on the formula that you provided, I think there is something wrong with it.

 

I have made a test on my side, please consider modify your formula as below:

 

SortByColumns(
Filter(
RoutingMethod,
RecordId in Filter(RoutingLink, GBERecordId = dd_SbgGbe.Selected.RecordID).RoutingRecordId,
Text(ActiveStatus) = "true",
If( /* <-- Modify your If function as here: */
OriginCountry = DestCountry,
RoutingType = "Both" || RoutingType= "Domestic",
RoutingType="Both" || RoutingType = "International"
)
),
"RoutinfCode",
Descending
)

Please consider take a try with above formula, then check if the issue is solved.

 

More details about Filter function and If function in PowerApps, please check the following article:

Filter function

If function

 

Best regards,

 

Community Support Team _ Kris Dai
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

9 REPLIES 9
svijay_001
Level: Powered On

Re: Multiple filters on 2 lists

Can you please elaborate on your requirement ? It is little confusing. 

svijay_001
Level: Powered On

Re: Multiple filters on 2 lists

@VineethKN 
Can you please elaborate on your requirement ? It is little confusing. 

Super User
Super User

Re: Multiple filters on 2 lists

Hi @VineethKN 

 

To compare the value between two dropdown selections, you can use if statement to achieve your needs:

If(Dropdown1.Selected.Result = Dropdown2.Selected.Result, true- do something , false - do something)
For the filter on third dropdown, you can modify your formula as below:

Filter(DataSource, Condition1 && If(Dropdown1.Selected.Result = Dropdown2.Selected.Result, <<Action if true>> ,<<Action if not true>>) && Condition2 )
Hope this Helps!

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!
VineethKN
Level: Powered On

Re: Multiple filters on 2 lists

Hi Yashag, thanks for the reply,

am getting error which i use Filters inside if condition Invalid Argument Type: expecting one of the following : boolean, number , text

what is that am doin wrong,

 

Super User
Super User

Re: Multiple filters on 2 lists

Hi @VineethKN 

 

Can you please share a snippet of the code/ screenshot of the error and the expression so that I can have a better look and assit you with this?

VineethKN
Level: Powered On

Re: Multiple filters on 2 lists

Am very new to Powerapps, so please pardon my syntax if it is wrong Smiley Happy

 

SortByColumns(Filter (
RoutingMethod,
RecordId in ShowColumns (
Filter (
RoutingLink,
GBERecordId = dd_SbgGbe.Selected.RecordID
),
"RoutingRecordId"
).RoutingRecordId && Text(ActiveStatus) = "true"
) If(OriginCountry = DestCountry, Filter(RoutingMethod, RoutingType = "Both" || RoutingType= "Domestic" ), Filter(RoutingMethod, RoutingType="Both" || RoutingType = "International")), "RoutinfCode" )

Super User
Super User

Re: Multiple filters on 2 lists

Hi @VineethKN 

 

Can you try:

SortByColumns
(
    Filter(RoutingMethod,
        If(OriginCountry = DestCountry,RoutingType = "Both" || RoutingType= "Domestic",RoutingType="Both" || RoutingType = "International")
        &&
        RecordId in Filter(
            RoutingLink,
            GBERecordId = dd_SbgGbe.Selected.RecordID
        ).RoutingRecordId
        &&
        Text(ActiveStatus) = "true"
)
Highlighted
Community Support Team
Community Support Team

Re: Multiple filters on 2 lists

Hi @VineethKN ,

Based on the formula that you provided, I think there is something wrong with it.

 

I have made a test on my side, please consider modify your formula as below:

 

SortByColumns(
Filter(
RoutingMethod,
RecordId in Filter(RoutingLink, GBERecordId = dd_SbgGbe.Selected.RecordID).RoutingRecordId,
Text(ActiveStatus) = "true",
If( /* <-- Modify your If function as here: */
OriginCountry = DestCountry,
RoutingType = "Both" || RoutingType= "Domestic",
RoutingType="Both" || RoutingType = "International"
)
),
"RoutinfCode",
Descending
)

Please consider take a try with above formula, then check if the issue is solved.

 

More details about Filter function and If function in PowerApps, please check the following article:

Filter function

If function

 

Best regards,

 

Community Support Team _ Kris Dai
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

VineethKN
Level: Powered On

Re: Multiple filters on 2 lists

Thanks a lot, it worked like charm

Helpful resources

Announcements
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

Demo Extravaganza Championship Voting Open

Voting Ends: October 30, 2019!

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

Top Kudoed Authors
Users Online
Currently online: 191 members 4,744 guests
Please welcome our newest community members: