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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Anonymous
Not applicable

Compare Two Columns from different tables in many to many relationship

How to compare two columns in a table visual coming from different tables, when their relationship is many to many?

 

PKR_0-1596278441443.png

In above image,

- The column "Supplier Name" is from a fact table.

- The columns "Vendor A" & "Vendor B" are from two different tables.

- The relationship between "Fact table" and "Vendor A" table is many to many.

 

How to compare "Supplier Name" & "Vendor A" and say they are matching or not?

 

Note: Since it is many to many relation, the related function is not working.

3 REPLIES 3
Anonymous
Not applicable

@Anonymous 

RELATEDTABLE function might work.

 

As @harshnathani suggests you should consider converting your model to start schema or use a bridge table for *:* relatioships.

 

harshnathani
Community Champion
Community Champion

Hi @Anonymous ,

 

Generally Supplier Name should come from a  Dimension Table adn should be related to your Vendor A and Vendor B Table.

 

I think you can try convert your model to a Star Schema.

 

Regards,

HN

 

 

 

 

lbendlin
Super User
Super User

what you are asking for is logically impossible.  Many to Many means there can be multiple rows in your fact table with supplier name MARUBENI and multiple rows in your Vendor A table with Vendor MARUBENI.  

 

You will want to reformulate your question, something like "How many times does the supplier name appear in the vendor table ?" so that you can actually get an answer.

 

 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.