The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
I have a fact table and a dimension in my model in Power BI :
ShipmentID SendingAgentCode ReceivingAgentCode
1000 12 13
1001 14 15
My model is like below :
I want to have two filters one for Receiving Agents and one for Sending Agents. How can I achieve that?
Also, I want to calculate the number of shipments for Receiving/Sending Agents separetly.
This is what I tried :
Solved! Go to Solution.
I ended up creating a separate table :
DimSendingAgent = ALL (DimAgent)
And then created the missing relationship to this new table. This is a common practice for relatively small tables using Power BI.
I ended up creating a separate table :
DimSendingAgent = ALL (DimAgent)
And then created the missing relationship to this new table. This is a common practice for relatively small tables using Power BI.
Hi, @amirabedhiafi
Please correct me if I wrongly understand your question.
In my opinion, please try to create two relationship lines inactive.
And when you create measures, you can use userelationship function in your measure to calculate per SendingAgent or per ReceivingAgent.
If it is OK with you, please share the sample pbix file, then I can look into it to come up with a more accurate solution.
Thank you.
Jihwan Kim
If this post helps, then please consider accept it as the solution to help the other members find it more quickly.
I already created two inactive relationships. I can't share the pbix file since it is containing sensitive data.
User | Count |
---|---|
68 | |
63 | |
59 | |
54 | |
28 |
User | Count |
---|---|
182 | |
81 | |
64 | |
46 | |
41 |