Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Given the following tables
Trip
ID
FromLocationID
ToLocationID
Location
ID
Name
City
I want to be able to use the location name for both the From and To in Trip but you can't create two active relationships. I can use Lookup, but if I wanted to reference City and Name, that becomes a pain, I really want to reference the entire table. I can add the Location table twice and link From and To separately but I think this duplicates the data in the Location table.
Is there a way to include a reference table twice but make the second a virtual copy of the first?
What's the best way to do this? In my actual model Location is used multiple times with several fact tables, with multiple location fields.
Thanks in advance for your help.
You can create an inactive relationship and use the DAX function USERELATIONSHIP to activate the inactive relationship. In this example, the active relationship would be between Location[ID] and Trip[FromLocationID]. The inactive relationship would be between Location[ID] and Trip[ToLocationID]. Example measure:
Count Trip ID - To Location =
CALCULATE (
COUNT ( Trip[ID] ),
USERELATIONSHIP ( Location[ID], Trip[ToLocationID] )
)
Proud to be a Super User!
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 40 | |
| 35 | |
| 34 | |
| 31 | |
| 28 |
| User | Count |
|---|---|
| 137 | |
| 102 | |
| 68 | |
| 66 | |
| 64 |