Forum Discussion
Measure does not show same value in different Visuals
- Anonymous10 months ago
Hi Luggas,
If the issue still persists, we kindly request you to share the sample data in a workable format such as text, an Excel file, or a PBIX file with sample data instead of screenshots. Additionally, please include the expected output. This will enable us to assist you more effectively.
Regards,
Prasanna Kumar
Hi Luggas
Reason:
- The card visual shows the total percentage for the entire dataset (overall context).
- The bar chart visual calculates each category (Volum1–Volum5) in its own row context.
That’s why, when you add up the five measures like this:
Visual = [VISUAL_Volum1] + [VISUAL_Volum2] + [VISUAL_Volum3] + [VISUAL_Volum4] + [VISUAL_Volum5]
It recalculates according to each context - so the total doesn’t match.
Fix:
If you want the same percentage across visuals, calculate each measure using the same denominator and same filter context (by using functions like CALCULATE, REMOVEFILTERS, or ALLSELECTED).Could you please try below steps:
1. Sample data that I used to solve the problem:
2. Create two measures:
Total % of Hours =
DIVIDE(
SUM('Sample Data'[Hours]),
CALCULATE(SUM('Sample Data'[Hours]), ALL('Sample Data'))
)Visual (All Categories) =
CALCULATE(
[Total % of Hours],
KEEPFILTERS('Sample Data'[Category] IN {"Volum1","Volum2","Volum3","Volum4","Volum5"})
)
3. Output: