Skip to main content
Announcements
Qlik Introduces a New Era of Visualization! READ ALL ABOUT IT
cancel
Showing results for 
Search instead for 
Did you mean: 
americanetsMD
Contributor III
Contributor III

Cumulative Sum

Hi everyone,

Consider the following table:

Spalte1Spalte2Spalte3Spalte4Spalte5Spalte7

ID CheckNr Year Period Sum(value) Cumulative EXPECTED
           
3002 3002295481 2022 01.2022 39.531,00 39.531,00
3002 3002131001 2022 01.2022 0,00 39.531,00
3002 3002295481 2022 02.2022 17.729,00 57.260,00
3002 3002131001 2022 03.2022 14.910,00 72.170,00
3002 3002280650 2022 04.2022 38.224,00 110.394,00
3002 3002280650 2022 05.2022 22.042,00 132.436,00
3002 3002280650 2022 06.2022 -7.395,00 125.041,00
3002 3002295481 2022 07.2022 -18.807,00 106.234,00
3002 3002131001 2022 08.2022 33.148,00 139.382,00
3002 3002131001 2022 09.2022 -18.827,00 120.555,00
3002 3002124331 2022 10.2022 11.340,00 131.895,00
3002 3002223674 2022 11.2022 -9.730,00 122.165,00
3002 3002305918 2022 12.2022 -7.425,00 114.740,00
3002 3002124331 2022 12.2022 -25.964,00 88.776,00
3002 3002124251 2023 02.2023 2.023,00 90.799,00
3002 3002131001 2023 03.2023 86.068,00 176.867,00
3002 3002131001 2023 04.2023 -136.292,00 40.575,00
3002 3002351693 2023 05.2023 3.207,00 43.782,00
3002 3002131001 2023 06.2023 102.385,00 146.167,00
3002 3002131001 2023 07.2023 -105.491,00 40.676,00
3002 keine Zuordnung 2023 08.2023 88.776,00 129.452,00
3002 3002124331 2023 08.2023 14.624,00 144.076,00
3002 3002223674 2023 08.2023 9.730,00 153.806,00
3002 3002305918 2023 08.2023 7.425,00 161.231,00
3002 3002280650 2023 08.2023 -22.965,00 138.266,00
3002 3002131001 2023 08.2023 -29.231,00 109.035,00
3002 3002295481 2023 08.2023 -38.453,00 70.582,00
3002 3002280650 2023 09.2023 19.170,00 89.752,00

 

I have a small problem on getting the right cumulative result(Cumulative EXPECTED) in the table.  The Cumulative Result must be calculated no matter the year  change. 

The Column (Cumulative EXPECTED) will be used in a pivot table, if this makes it somehow easier.

Can anyone please help me with this. I am sure it has  to be easy but i just can't get to that logic. 😞

Labels (1)
1 Solution

Accepted Solutions
sidhiq91
Specialist II
Specialist II

@americanetsMD  You can use the below expression to get the desired output.

Rangesum(Above(total Sum(value),0,RowNo(Total)))

if this resolves your issue, please like and accept it as a solution.

View solution in original post

2 Replies
sidhiq91
Specialist II
Specialist II

@americanetsMD  You can use the below expression to get the desired output.

Rangesum(Above(total Sum(value),0,RowNo(Total)))

if this resolves your issue, please like and accept it as a solution.

americanetsMD
Contributor III
Contributor III
Author

Hello Sidhiq91,

sorry for late answer. I have tried your expression and it work marvelous. Thank you.