Forum Discussion
AndreaLorenzo
1 year agoFrequent Visitor
Cummulative sum for different years with month filter
Hi everybody, I am struggling to get a cummulative sum when displaying data in a matrix for different years and with a month filter. I can get this year's amount correct, but for the pr...
- 1 year ago
AndreaLorenzo Try using this
DAX
Ventas Acumuladas =
CALCULATE(
SUM(Ventas_Ppto_Forecasting[Importe_Real]),
FILTER(
ALL(PBI_Calendario),
PBI_Calendario[Año] = MAX(PBI_Calendario[Año]) &&
PBI_Calendario[Mes] <= MAX(PBI_Calendario[Mes])
)
)
bhanu_gautam
Super User
1 year agoAndreaLorenzo Try using this
DAX
Ventas Acumuladas =
CALCULATE(
SUM(Ventas_Ppto_Forecasting[Importe_Real]),
FILTER(
ALL(PBI_Calendario),
PBI_Calendario[Año] = MAX(PBI_Calendario[Año]) &&
PBI_Calendario[Mes] <= MAX(PBI_Calendario[Mes])
)
)
AndreaLorenzo
1 year agoFrequent Visitor
bhanu_gautam Sorry, you were right! The problem was I was using a wrong "year" field when displaying the matrix... My bad!😅