Create a Measure called Total Revenue:
Total Revenue =
SUMX(
CALCULATETABLE(
'vw_PandL',
'vw_PandL'[Line] = "Total Revenue"
),
[MTH]
)
Create another Measure called %:
% = VALUES(vw_PandL[MTH]) / [Total Revenue]
And it will work with filters applied.
When creating reports that include calculated percentages using DAX, it’s important to also consider how these reports will appear on different screen sizes and devices. A common issue users encounter is that Power BI visuals do not resize properly, leading to misaligned or cropped visuals when viewed on smaller screens, external monitors, or mobile devices.
Preparing for Power BI exam? Check out Power BI Syllabus now!