Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello Fabric Community,
I'm trying to solve this DAX/Model problem, here's the scenario.
I have a dimension table with an event called "original sailing key" and "mapped saling key", the problem I have is the "mapped" key has duplicate values so my inactive relationship is a many-to-many type.
Measure:
This is causing my measure "Revenue (Mapped)" to work incorrectly with the duplicate values.
How can I adjust my measure to work around the duplicate values and bringing in the right revenue amount?
Data model:
Hi @esulyma ,
Based on the description, try to create a bridge table and the table stores the unique sailing key.
Then, create the relationship between the bridge table and passenger table, sailings table.
What’s more, try to modify the measure to the following dax formula.
Revenue (Mapped) =
CALCULATE(
[Revenue],
USERELATIONSHIP('BridgeTable'[Sailing Key], 'Sailings'[Mapped Sailing Key])
)
You can also view the following documents to learn more information.
USERELATIONSHIP function (DAX) - DAX | Microsoft Learn
Many-to-many relationship guidance - Power BI | Microsoft Learn
Best Regards,
Wisdom Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hello! Thanks for your reply, I tried this before without any sucess.
I gave it another shot with your guidance, below are the changes I made where it shows the unexpected results.
Data model:
Visual view where the Revenue (Mapped) measure doesn't show the expected value for mapped (starting in $9):
Am I doing something wrong?
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
23 | |
7 | |
7 | |
6 | |
6 |
User | Count |
---|---|
27 | |
12 | |
10 | |
9 | |
6 |