Discussion board where members can learn more about Qlik Sense App Development and Usage.
Hi Community,
I need to count the consecutive times that I have a "e" value, I managed to add the 1/0 value but now I need to sum these values.
I need to count the consecutive times I have a 1, but when I have a 0 I need to start again, any Ideas on how can I do it?
Thanks
Then set the label of this expression prev_read2 and use:
If(Above(TOTAL START_READ_TYPE)='e',Above(TOTAL [prev_read2])+1,0)
Hi, if prev_read is the label of the last expression an is calculated as:
If(Above(TOTAL START_READ_TYPE)='e',1,0)
The accumulation could be:
If(Above(TOTAL START_READ_TYPE)='e',Above(TOTAL [prev_read])+1,0)
It will be flagged as an error but it should work
Hi @rubenmarin ,
Thanks for your answer, it;s not working as I expect, as you can see it shows always 2, but I am expecting..3,4,5,6 in these rows
This expression was to sustitute the prev_read expression, for this to work this expression needs to be labeles as prev_read, or change the expression and the label so it uses the previous value if this same expression.
It always shows 2 because there is other prev_read expression with 0 or 1.
prev_read is created in the script using:
,If(START_READ_TYPE = 'e' and Peek([START_READ_TYPE]) ='e', 1,0) as prev_read
Then set the label of this expression prev_read2 and use:
If(Above(TOTAL START_READ_TYPE)='e',Above(TOTAL [prev_read2])+1,0)
@rubenmarin Thanjs man!