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: 
Not applicable

suggest

Hi,


I need display top2 amounts by components

My script looks like as below

Rank(Aggr(Sum({<mobile={'=Rank(Sum(amount))<=3'}>}amount),component),component)

but not getting accurated output.

This is my Expected Output table

   

mobileamount
93500
94400
85500
84400
73500
72400

Source Table:

   

mobilecomponentamount
91roaming100
92roaming300
93roaming500
94roaming200
95roaming400
81gprs100
82gprs200
83gprs300
84gprs400
85gprs500
71sms300
72sms400
73sms500
74sms200
75sms100
Labels (1)
1 Solution

Accepted Solutions
sunny_talwar
MVP
MVP

Try this:

=Sum(Aggr(If(Rank(Sum(amount)) < 3, amount), component, mobile))

View solution in original post

1 Reply
sunny_talwar
MVP
MVP

Try this:

=Sum(Aggr(If(Rank(Sum(amount)) < 3, amount), component, mobile))