I have a table with Name column, Month column, Year column and Income columns. I will put an image here, but here is column description in text:
The Year and Month columns are just integers. Like: 1 is January in the Month column and 6 is for example June in the Month column.
Income columns are named as days so: 1, 2, 3, 4... and each are a floating point data type with values like 13 470,50 etc.
I have the Year and Month set as my page filter. For example Month = 4 and Year = 2023.
I am trying to write a DAX that takes the Month of the filter (So 4 in our example) PLUS ALL THE MONTHS PRIOR (So Month 1 + Month 2 + Month 3 + Month 4) and add up all the incomes in the Income columns.
In other words add up values in the 31 income columns and add that number cumulatively for each month until the month that is in the filter.
What I tried:
Hi,
For running total I recommend reading this article: Computing running totals in DAX - SQLBI
In your case here is an example:
data:
I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!
My LinkedIn: https://www.linkedin.com/in/n%C3%A4ttiahov-00001/
Proud to be a Super User!
Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!