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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
Renna
Frequent Visitor

Use the Column Subtotals in Matrix as YTD column

Hi, 

I'm aiming to maintain the Column Subtotal in a Matrix as YTD, while other columns represent individual months. It works perfectly without any month filters applied (the total is sum of all months, which is coincidently YTD values):

Renna_0-1711146159586.png

But applying a month filter alters the Total column to reflect only the selected month(s).

Renna_1-1711146250201.png

Can the Total column always reflect the sum of all months, unaffected by month filters?

1 ACCEPTED SOLUTION

Hi @Renna ,
Change your YTD Revenue dax as follow.

YTD Revenue = IF(ISINSCOPE('Sample Table'[Period]),
CALCULATE(SUM('Sample Table'[Revenue])),
CALCULATE(SUM('Sample Table'[Revenue]), ALL('DimDates'[Date].[Month]))
)

I only changed here.
ALL('DimDates'[Date].[Month])

Thanks

View solution in original post

6 REPLIES 6
Renna
Frequent Visitor

Hi @AUDISU ,
Thanks very much for your response. However it's not working 😔

Renna_0-1711379070343.png

 

Hi @Renna ,
Can you share your sample pbix file.

As I think you have added wrong field to ALL function.
Thanks

Renna
Frequent Visitor

Hi @AUDISU ,

This is the LINK to pbix file. Thank you very much!

Hi @Renna ,
Change your YTD Revenue dax as follow.

YTD Revenue = IF(ISINSCOPE('Sample Table'[Period]),
CALCULATE(SUM('Sample Table'[Revenue])),
CALCULATE(SUM('Sample Table'[Revenue]), ALL('DimDates'[Date].[Month]))
)

I only changed here.
ALL('DimDates'[Date].[Month])

Thanks

Renna
Frequent Visitor

It works! Thank you so much!

AUDISU
Resolver III
Resolver III

Hi @Renna ,

use INSCOPE function.
Dax query should be like follow.

Change the table and column names as your data model.
Amount = IF(INSCOPE(Calender[Month]) , CALCULATE(SUM('Sales'[SalesAmount])),CALCULATE(SUM('Sales'[SalesAmount]) , ALL(Calender[Month]))

Thanks
DISU.

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.

Top Solution Authors
Top Kudoed Authors