- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Modelling Many to Many Relationship and Counting Unique and Non-Unique Relationships
I have 2 fact tables that consist of unique values that are related to one another through an additional item-relationship:
Fact 1
Fact 2
Item Relation Table - As seen here, not every item in Fact 1 has a relationship to an item in Fact 2, and vice-versa
Currently for visualization purposes, I have the following model. A visual table containing Items A needs to be able to filter another table with Items B down to the items related on selected Item A. (Ex. "1" is selected in one table, and the other table will filter down to A, B, and C)
I have 2 questions regarding this model.
1) Obviously setting up the model like this is going to cause severe performance issues. Is there an alternate way to model this without having to combine Fact 1 and Fact 2 and grow the table exponentially?
2) I need to create DAX measures to indicate for every Item B, the count of times it is the only related item to Items A, and the count when it is not the only item related to Item A. Example below of what the table should look like. Also, preferably, when selecting an Item B, another table will filter down to the related Items A.
Item B | Unique Count | Non Unique Count |
A | 1 | 2 |
B | 1 | 2 |
C | 0 | 1 |
D | 0 | 0 |
Any help is much appreciated!
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

For your reference.
"Model view"
Selection "B" of "ItemB" on "Report view"
Selection "2" of Item A on "Report view"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hi @orihime0 ,
Whether the advice given by mickey64 has solved your confusion, if the problem has been solved you can mark the reply for the standard answer to help the other members find it more quickly. If not, please point it out.
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

For your reference.
"Model view"
Selection "B" of "ItemB" on "Report view"
Selection "2" of Item A on "Report view"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

I'm curious why Item A has a completely different set of values from Item B. How do you know which Item A value is related to that from Item B?
Dane Belarmino | Microsoft MVP | Proud to be a Super User!
Did I answer your question? Mark my post as a solution!
"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

As posted above, they are related to eachother through the Item Relation table:

Helpful resources
Subject | Author | Posted | |
---|---|---|---|
02-12-2025 10:51 AM | |||
10-22-2024 03:41 AM | |||
10-26-2024 02:40 PM | |||
07-08-2024 09:12 AM | |||
06-26-2017 10:16 AM |
User | Count |
---|---|
121 | |
104 | |
88 | |
52 | |
45 |