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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
tintinsherlock
Microsoft Employee
Microsoft Employee

How to keep the rows of one CSV/table based on common value in column in another CSV/table?

I did not know how to put my question properly in the Subject so I will elaborate. 

Suppose I have one table (imported through a CSV/TSV) which looks like this - 

ColumnAColumnB
1Liz Lemon
2Michael Scott
1Chandler Bing
3Ron Swanson
4David Rose

 

I have another table (imported through a CSV/TSV) which has only one column

 

ColumnA
1

 

I want to show only those rows in the first table for which ColumnA values match the ColumnA values in the second table.

So the output I want is

 

ColumnAColumnB
1Liz Lemon
1Chandler Bing


I want to show this final output above inside a TABLE visual in the report. 
I have tried INNER JOIN-ing the two tables but the result somehow doesn't get reflected in the TABLE visual, which is what I need. 
Please help if possible.

1 ACCEPTED SOLUTION

I don't want to use a visual level filter as both the columns actually have a LOT of rows. 

View solution in original post

5 REPLIES 5
johnt75
Super User
Super User

If the table with only 1 column has unique values then you can create a 1-to-many relationship between the tables and use ColumnA from the 1 side in your table visual along with ColumnB from the many side.

MFelix
Super User
Super User

Hi @tintinsherlock ,

 

Merge Table one with table two based on the column A, then select rigth outer:

https://docs.microsoft.com/en-us/power-query/merge-queries-overview


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Thanks. I tried this and this worked.

amitchandak
Super User
Super User

@tintinsherlock , Create a measure and use that with the ungrouped column of a table 1 or use a visual level filter

 

measure =

countrows(filter( Table1, Table1[ColumnA] in values(Table2[ColumnA]) ) )

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

I don't want to use a visual level filter as both the columns actually have a LOT of rows. 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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