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
bourne2000
Helper V
Helper V

Can we match one column from one table to other table?

Hi

 

I have below two tables

 

 Table 1 
NameEmailSchool
Katekate@abc.comabc
Smithsmith@abc.comabc
Johnjohn@abc.comabc

 

 Table 2 
NameEmailSchool
Kateskates@abc.comabc
Smith josmithjo@abc.comabc
Johnjohn@abc.comabc

 

I want to check if the name column of Table 2 is present in Table 1. We can see different names are present in table 1.

Kates, Smith jo is not available in Table 1, hence I need to print these records in the different table.


I need output as below

 

 

 Output 
NameEmailSchool
Kateskates@abc.comabc
Smith josmithjo@abc.comabc

 

Both tables don't have any relationship. If I try to connect both the tables, it's coming many to many relationships. Can anyone please advise. I tried vlookup but no success.

1 ACCEPTED SOLUTION
Jihwan_Kim
Super User
Super User

Hi, @bourne2000 

Please check the below picture and the formula for creating a new table.

 

Picture1.png

 

Output Table =
SUMMARIZECOLUMNS (
Table2[Name],
Table2[Email],
Table2[School],
FILTER ( Table2, NOT ( Table2[Name] IN VALUES ( Table1[Name] ) ) )
)

 

https://www.dropbox.com/s/xqcq4seqgypia8i/bournev2.pbix?dl=0 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Go to My LinkedIn Page


View solution in original post

2 REPLIES 2
Ashish_Mathur
Super User
Super User

Hi,

I have solved it using the Query Editor.  You may download my PBI file from here.

Hope this helps.

Untitled.png


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Jihwan_Kim
Super User
Super User

Hi, @bourne2000 

Please check the below picture and the formula for creating a new table.

 

Picture1.png

 

Output Table =
SUMMARIZECOLUMNS (
Table2[Name],
Table2[Email],
Table2[School],
FILTER ( Table2, NOT ( Table2[Name] IN VALUES ( Table1[Name] ) ) )
)

 

https://www.dropbox.com/s/xqcq4seqgypia8i/bournev2.pbix?dl=0 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Go to My LinkedIn Page


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.