Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Measure Not Working With Relationship?

Hi,

 

I have two tables.

 

First is the fact table with my transactions, in which I have the Customer Name and order intake.

Second is the dim table with Customer Name and Customer Segment, Customer Type.

 

There is a relationship between dim_Customer and fact_Install based on Customer Name. The relationship is many to one with a single cross filter direction.

 

There is also a calendar table because I have measures like:

Order-Intake-CY =
switch(SELECTEDVALUE(dim_Scenario[Scenario]),
"MTD",TOTALMTD([Order-Intake-Sum],'dim_Calendar'[Date]),
"QTD",TOTALQTD([Order-Intake-Sum],'dim_Calendar'[Date]),
"YTD",TOTALYTD([Order-Intake-Sum],'dim_Calendar'[Date]))

Order-Intake-Sum = 
sum(fact_Install[Order Intake])

 

Current Output:

Output02.JPG

 

Desired Output (I have used the column from fact_Install table instead of measure, but I need a measure to show various scenarios MTD QTD YTD):

Output01.JPG

 

 

5 REPLIES 5
V-lianl-msft
Community Support
Community Support

Hi @Anonymous ,

 

This may cause by the context of the measure.

Based on your description, the relationship between the two tables is created based on the customer name, and the context used in the pie chart is Customer Segment?

There is no direct relationship between customer segment and order intake.

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

But the customer segment is part of the dim_Customer table and the order intake is part of fact_Install table. 

 

So, if I have a dataset like mentioned on top - how can I show the order intake by customer segment?

amitchandak
Super User
Super User

@Anonymous , I am assuming you have created a measure slicer. Remember in Time intelligence, if date is not selected on-page, the end date of ytd, mtd,qtd will end date of the calendar . So that can be an issue.

 

Slicer -https://radacad.com/change-the-column-or-measure-value-in-a-power-bi-visual-by-selection-of-the-slicer-parameter-table-pattern

Power BI — YTD Questions — Time Intelligence 1–5
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
Power BI — QTD Questions — Time Intelligence 2–5
https://medium.com/@amitchandak.1978/power-bi-qtd-questions-time-intelligence-2-5-d842063da839
Power BI — MTD Questions — Time Intelligence 3–5
https://medium.com/@amitchandak.1978/power-bi-mtd-questions-time-intelligence-3-5-64b0b4a4090e

 

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hi @Anonymous ,

 

Try to add the Customer Name to the legend.

 

Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Anonymous
Not applicable

@amitchandak 

 

thank you for your reply. Yes, I do have a measure slicer in which users select a particular month and year. However, I still don't understand why my measure is not working.

 

I noticed that when I added a calculated column (lookup with customer name to get the customer segment) to my fact table, all visuals behave as expected... but why it is not working without these calculated columns, just based on the relationship?

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.