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
Islam
Helper V
Helper V

help on hiding months with no allocated values in a matrix

 

Hello Everyone

i'm trying to create a matrix showing the Pouring Amount which represents Revenue and Total Expenses which is the sum of Expenses and Purchased materials 

so i created the following measures

 

Total Materials Amount:=SUMX('Total Amounts','Total Amounts'[Materials Amount])

 

 

Total Expenses Amount:=SUMX('Total Amounts','Total Amounts'[Expenses Amount])

 

Total Pouring Amount:=SUMX('Total Amounts','Total Amounts'[Pouring Amount])

 

 

Net Profit/Loss:=[Total Pouring Amount]-[Total Expenses]

and that's how i wanna show the pivot table

Islam_0-1621598374605.png

 

i have no values for January 2020 but there are values for January 2021 so when i filter to show just January 2021 (It's Called يناير) with years rows displayed i get the correct values for January 2021 but an empty month for 2020 with the sum of all 2020 values like following picture

Islam_1-1621598374640.png

 

I want to hide 2020 January with no values and also fix the grand total calculation

Any help would be highly appreciated

1 REPLY 1
lbendlin
Super User
Super User

Change

 

Net Profit/Loss:=[Total Pouring Amount]-[Total Expenses]

 

to account for situations where ISBLANK([Total Pouring Amount]) is true.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.