Forum

Cumulative total ex...
 
Notifications
Clear all

Cumulative total expression error

4 Posts
2 Users
0 Reactions
69 Views
(@lindac)
Posts: 32
Trusted Member
Topic starter
 

Hi,

I wish to add a custom column for the cumulative quantity. I wish to use the simple DAX pattern from https://www.daxpatterns.com/cumulative-total/ that I have pasted below. The DAX pattern got a green tick and "No syntax errors have been detected."

However, when I applied the formula, I got this message "Expression.Error: The name 'CALCULATE' wasn't recognized. Make sure it's spelled correctly". Any idea how I correct this? Thank you!

 
Cumulative Quantity :=
CALCULATE

(

    

SUM ( Transactions[Quantity] ),

    

FILTER (

        

ALL ( 'Date'[Date] ),

        

'Date'[Date] <= MAX ( 'Date'[Date] )

    

)

)

 
Posted : 21/06/2019 3:27 am
(@catalinb)
Posts: 1937
Member Admin
 

Hi Linda,

I am sure you know that there are differences between power BI web version and the Desktop version. You are not clear about the environment where you are using that formula, but I guess you are trying to do that in the web version. That will work only in Desktop version.

 
Posted : 21/06/2019 2:29 pm
(@lindac)
Posts: 32
Trusted Member
Topic starter
 

Hi Catalin,

That error was in Power BI desktop. Any help appreciated. Thank you.

Linda

 
Posted : 22/06/2019 12:48 am
(@lindac)
Posts: 32
Trusted Member
Topic starter
 

Hi Catalin,

I solved it. In the Values well, I just selected the field I wanted and created a new quick measure that was 'Running Total'. Thank you!

Linda

 
Posted : 22/06/2019 4:08 am
Share: