March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi everyone,
For a report on stock flows I need to have the name of both the "From" location and "To" location. Both these entities are related to the same warehouse location dimension. Power BI only allows only 1 single active relationship:
So I will need to "calculate" the other name manually. (I can't copy the Warehouse table due to RLS role constraints).
I used the following DAX statement to manually force PBI to use the inactive relationship:
NameTo = CALCULATE( VALUES(Warehouse[Name]); USERELATIONSHIP(Warehouse[ID]; Flow[To]) )
The result gives me the same name as the active relationship which I don't want.
Can anyone help me with my statement?
Thanks in advance,
Harm
Solved! Go to Solution.
Hi @Anonymous,
I would not use the relation between both table I would do two columns on your data table with the following syntax:
From name = LOOKUPVALUE(Warehouse[Name], Warehouse[ID] , Flow[From]) To name = LOOKUPVALUE(Warehouse[Name], Warehouse[ID] , Flow[To])
If you want to use the column with the user relationship you need to make the column on the Flow table and not on the wharehouse table as you have that's why you have the same name always.
Regards,
MFelix
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi @Anonymous,
I would not use the relation between both table I would do two columns on your data table with the following syntax:
From name = LOOKUPVALUE(Warehouse[Name], Warehouse[ID] , Flow[From]) To name = LOOKUPVALUE(Warehouse[Name], Warehouse[ID] , Flow[To])
If you want to use the column with the user relationship you need to make the column on the Flow table and not on the wharehouse table as you have that's why you have the same name always.
Regards,
MFelix
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsMarch 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
133 | |
90 | |
88 | |
64 | |
58 |
User | Count |
---|---|
201 | |
137 | |
107 | |
70 | |
68 |