If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.
I was facing a challenge to perform the calculation in the front end.
The cumulation need to be done based on the flag as a condition,
below is the example,
|4||1||10||15||(10+15)||Cumulating all records above having flag 1|
|5||2||10||20||(10+10)||Cumulating all records above having flag 2|
|6||3||6||16||(10+6)||Cumulating all records above having flag 3|
|7||1||4||19||(10+15+4)||Cumulating all records above having flag 1|
|8||2||6||26||(10+10+6)||Cumulating all records above having flag 2|
|9||3||8||24||(10+6+8)||Cumulating all records above having flag 3|
The requirement is such a way, the calculation has cannot be done in the backend.
Please help us with the expression.
Thanks in advance,
Thanks for the reply.
The expression is working perfectly, in the sample file shared. I tried to apply the same in my file, it bit tricky for me to understand the expression in what way it goes wrong.
Please have a look at the attached application, in which I'm working on.
To be clear on what I'm trying to achieve is to roll up every 20th from the start.
Assuming the fact the person leaves at every 20th day, no. of people leaves creates the vacant for next day (21st Day). Thats the reason why the Flag column is created to rolling down the values every 20 days.
Hope the above logic description is understandable.
As I explained in the header example, I need to accumulate the values of the 3rd record respectively. The expression suggested is working fine in the provided sample file.
When I tried to apply the same in the application(recently attached qvf) in which I'm working on. The expression isn't working correctly as expected.
In the previous reply, I tried to explain the business behind the logic I'm working on. If open the qvf, the patient admitted is the same, for 1st cycle which is 1-20 days, when the next cycle starts, 1st cycle patient moves away and beds occupied by them is assigned to the person comes in 2nd cycle (21-40 days). Likewise, it goes on till the date entered in the data.