Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Anonymous
Not applicable

Table SelectRows with multiple conditions: each List contains

Dear community member,

 

does anyone know if it is possible to use Table. SelectRows function with multiple each List.Contains clauses that returns the value based on several lists. I try to get the data that filtered by list A, list B and another condition. The source table is the same, so I used steps as below

step 1: Table. SelectRows( source_table, each List.Contains(List A, [columnA]))

step 2: Table. SelectRows(source_table, each List.Contains(List B,[columnB]))

step 3: Table. SelectRows(source_table, each List.Contains(List B,[columnC]))

step 4: Table.SelectRows(source_table,[columnB]=[columnC] )

however, only one of step will be applied. If step 4 is applied, my data will not be filtered by Step 1 to Step 3.

Any suggestions for combining the conditions?

Thank you all in advance

 

Best regards,

Chiao

 

1 ACCEPTED SOLUTION
HotChilli
Super User
Super User

Assuming that the syntax is correct and each step does what it's supposed to do:

Do you want to 1) apply each step successively to filter the dataset or 2) do you want to filter the dataset with 4 queries and then "union" the results

If 1) -> Each step is being given the same source_table, if you want to have each step applied on the previous step the code has to refer to the previous named stage. The stages are named in Advanced Editor so replace source_table with the previous step name.

If 2)-> You can use the Table.Combine syntax

View solution in original post

2 REPLIES 2
HotChilli
Super User
Super User

Assuming that the syntax is correct and each step does what it's supposed to do:

Do you want to 1) apply each step successively to filter the dataset or 2) do you want to filter the dataset with 4 queries and then "union" the results

If 1) -> Each step is being given the same source_table, if you want to have each step applied on the previous step the code has to refer to the previous named stage. The stages are named in Advanced Editor so replace source_table with the previous step name.

If 2)-> You can use the Table.Combine syntax

Anonymous
Not applicable

Hello HotChilli,

Thank you so much!

I want to apply the steps successively to filter the data.

The problem is solved!

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors
Top Kudoed Authors