Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
pgonin
Contributor II
Contributor II

count values in previous months

Hello dears!

May I ask you a pretty (hopefully) simple question.

Let's say I have a model consisting of period and id, like this:

periodid
2019-09a
2019-09b
2019-08c
2019-08d
2019-07e
2019-07f
2019-07g
2019-06h

And then, on a new app on a new sheet I want a pivot table with period as a dimension and count of id's for 3 previous periods as a measure: like this as a result

periodcount of ids for 3 previous periods
2019-097
2019-086
2019-074
2019-061

 

How would one do so?

I don't want it to do in the load editor as this is a simple example, actual values rely on other filtered values, etc.

Labels (1)
  • Chart

1 Reply
Anil_Babu_Samineni

Try 

RangeSum(Above(Count(id), 0, 3))

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful