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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Bruno_Soares_25
Regular Visitor

Calculated Measure not showing the column total

I've been trying to fix this last week sales for a while and its working on a row basis but as a column its not giving me the total which I need for other measures.

 

Basically i've got this formula

 

Prev Cost =
CALCULATE(
    SUM(table[Cost (EUR)]),
FILTER(
        ALL('table'),
        'table'[Date] < MIN('table'[Date]) &&
        'table'[Date] >= MIN('table'[Date]) - 7
    )
)
Bruno_Soares_25_0-1711025567711.png

 

This is the outcome which on a row to row basis is correct but its not giving me any total column value, I've tried a bunch of things but im pretty new to DAX also so need a buoy 

 

Thanks

 

1 ACCEPTED SOLUTION
v-tangjie-msft
Community Support
Community Support

Hi @Bruno_Soares_25 ,

 

We can create a new measure.

Measure =
SUMX ( SUMMARIZE ( 'Table', [Year], [Week], "pre", [Prev Cost] ), [pre] )

Then the result is as follows.

vtangjiemsft_0-1711435036945.png

Best Regards,

Neeko Tang

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

View solution in original post

2 REPLIES 2
v-tangjie-msft
Community Support
Community Support

Hi @Bruno_Soares_25 ,

 

We can create a new measure.

Measure =
SUMX ( SUMMARIZE ( 'Table', [Year], [Week], "pre", [Prev Cost] ), [pre] )

Then the result is as follows.

vtangjiemsft_0-1711435036945.png

Best Regards,

Neeko Tang

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

lbendlin
Super User
Super User

What is your expected result?  Keep in mind that the row totals section will have ALL the selected dates, and therefore your filter will fall off the lower end of the date range, returning nothing.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.