Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
sonikajain
Partner - Contributor
Partner - Contributor

Top 10 rows and total of top 10

Dear all,

I need to implement a straight table where the top 10 rows based upon a particular measure are to be displayed, and then the total of the top 10 rows  as the 11th row.

Please sugeest ways to implement this.

13 Replies
p_verkooijen
Partner - Specialist II
Partner - Specialist II

In QV11 you can use Dimension Limits for top 10, then use sum of rows in expression for totals

sonikajain
Partner - Contributor
Partner - Contributor
Author

thanks, am using qlikview 10 , please suggest..

SunilChauhan
Champion II
Champion II

see the attached file

hope this helps

Sunil Chauhan
SunilChauhan
Champion II
Champion II

you can use this formula

in expression

If(aggr(rank(sum([Error Count])),EmployerName)<=10,[Error Count])

i.e

If(aggr(rank(sum(Valuefield)),keyfield)<=10,Valuefield)

hope this helps

Sunil Chauhan
sonikajain
Partner - Contributor
Partner - Contributor
Author

Thanks very much Sunil...it worked, am able to fetch top 10 rows and the total of top 10.

Please help me in getting the total of remaining rows(ALL OTHERS) and the total of ALL ROWS in the same chart.

As soon as I apply the aggr function, the ALL  OTHERS and ALL ROWS have disappeared from the chart even though I make them selected in the properties chackbox.

Please advise.

sonikajain
Partner - Contributor
Partner - Contributor
Author

hey..this s giving me lowest 10 rows....can u please help me getting the TOP 10 in descending order....the data coming from load scritp is not ordered..and I cannot touch that too....

SunilChauhan
Champion II
Champion II

see the attched

apply accordingly

hope this helps

Sunil Chauhan
sonikajain
Partner - Contributor
Partner - Contributor
Author

am not able to open the file ...can u give the settings here for ALL OTHERS and TOTAL...

SunilChauhan
Champion II
Champion II

use formula like below  in expression for others

If(aggr(rank(sum([Error Count])),EmployerName)>10,[Error Count])

hope this helps

Sunil Chauhan