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
leroy773
Helper II
Helper II

Calculate running total

All,

 

I am attempting calculate a running total.  I am able to calculate the running total, but graphing the data is not showing the results I would like to see.  Which formula should I use to show running total?  Thanks

 

If I use TOTALYTD, is does not include prior year data and current year data.

Install Base = TOtalYTD(COUNTROWS('BI Sequel Installed Instruments'),DateDimension[DateKey])

 

graph.PNG

 

If i use calculate function it shows the total number for each qtr instead of incremental growth.

Install Base = CALCULATE(COUNTROWS('BI Sequel Installed Instruments'),DateDimension[DateKey])

 

Capture.PNG

 

 

1 ACCEPTED SOLUTION
TomMartens
Super User
Super User

Hey,

 

I guess here you find what you are looking for

 

http://www.daxpatterns.com/cumulative-total/

 

Hope this helps



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

2 REPLIES 2
TomMartens
Super User
Super User

Hey,

 

I guess here you find what you are looking for

 

http://www.daxpatterns.com/cumulative-total/

 

Hope this helps



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany
BetterCallFrank
Resolver IV
Resolver IV

Hi @leroy773

 

pls try something like this:

 

Install Base YTD = 
VAR vYear = YEAR(MAX(DateDimension[DateKey]))
VAR CurrDateKey = MAX(DateDimension[DateKey]
RETURN
CALCULATE(
  COUNTROWS('BI Sequel Installed Instruments'),
  ALL(DateDimension),
  DateDimension[Year] = vYear,
  DateDimension[DateKey] <= CurrDateKey
)

HTH,

Frank

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.