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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
gadao
Frequent Visitor

Filter table based on other table

I have a table with 10 columns and another one with 1 or more columns, but no more than 10. This second table have the same columns names the first have, but maybe not all columns.

 

The idea is to use this second table as filter to the first.

 

The problem is that the number of columns of this second table may vary dependening of the need of filtering one or more column.

 

How do I dinamically filter the first table based on second table, knowing that the number of columns may vary?

3 REPLIES 3
v-jingzhang
Community Support
Community Support

Hi @gadao 

 

You can try the Append Queries feature. Select the table with 10 columns as the primary table and append the other table below it. The append operation is based on the names of the column headers in both tables, and not their relative column position. The final table has all matching columns from all tables appended. If the tables don’t have matching columns, null values are added to the unmatched column. 

 

I'm not sure how you would like to filter the first table with the second table. With above appended table, if you want to remove the duplicated values in one or some columns, you can select that column (or hold on Ctrl key and select multiple columns) then select Home > Reduce Rows > Remove Rows > Remove Duplicates. If you want to remove duplicated rows, you can select all columns and perform above Remove Duplicates operation. 

 

If you want to keep the same data which exist in both tables, you can first select Reduce Rows > Keep Rows > Keep Duplicates. Then Remove Duplicates to keep the distinct rows from the remained rows. 

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

Vijay_A_Verma
Super User
Super User

If you can post sample layouts of both tables and explain the filtering with respect to posted pictures, then experts here would be able to help you. 

ronrsnfld
Super User
Super User

You may be able to do with by Joining the two tables. 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors