Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
NormanStanleyBadger
Creator
Creator

Nested Ranking

Hello, hopefully everybody is good 😎

I would like some help, please, to calculate a nested ranking. I have the expression below to return the Top 40 customers in a synthetic dimension. Now I would like to provide further views but

  • Specifically within the Top 40
  • Against other measures (i.e. Worst 5 performers against budget of the Top 40 etc)

Is this possible?

Thanks in Advance 

NSB

Aggr(

If(

Rank([Sales]) <= 40,

[Customer]
),

[Customer]
)

Labels (5)
1 Reply
NormanStanleyBadger
Creator
Creator
Author

OK, the following seems to work, but please let me know if you can think of any objections. Also, my back up is to create a top vendor flag dimension in the script but I would prefer it to be dynamic at this point.

Aggr(

If(
Rank(

If(
Rank([Sales]) <=40,
- (Budget Variance])
)
) <= 3,

[Customer]
),

[Customer]
)