Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Ranking by 1 measure while showing the data for other measures

Hi I'm using the following to rank a table based on 1 measure and limiting the  rows to 25.

=aggr(if(rank(-Q_DCIPU,Q_DCIPU )<=25, Q_DCIPU ),Q_DCIPU )

I want to include more data columns while maintaining the same 25 rows as follows based on the same ranking

AssetQ_DCIPUSDWPUINDEX
A11500.50
B1.50100.01
C2.2560.60
D2.2670

0.40

E5.99990.06

However, when I try something like

=aggr(if(rank(-Q_DCIPU,Q_DCIPU )<=25, SDWPU ), SDWPU )

and

=aggr(if(rank(-Q_DCIPU,Q_DCIPU )<=25, INDEX ), INDEX )


I get a result similar to the following and more rows due to the ranking function as each measure adds another row until the 25 rank values are showing for each measure which is what I don't want

AssetQ_DCIPUSDWPUINDEX
A1--
B1.50100.01
C2.256-
D2.26--
E5.99-0.06

hope you can help and appreciate it if you can

4 Replies
Thiago_Justen_

Maybe I'm missing anything but, why didn't you using the same rank expression for other columns?

Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago
Anonymous
Not applicable
Author

Hi Thiago

thanks for the reply

can you write the expression you refer to based on the result I'm looking for so I can try it?

thanks

Thiago_Justen_

I was refering this one:

=aggr(if(rank(-Q_DCIPU,Q_DCIPU )<=25, Q_DCIPU ),Q_DCIPU )


but I guess I have a missread here...


Maybe you could try those ones above that you mentioned using this sintax:


=aggr(if(rank(-Q_DCIPU,Q_DCIPU ,3)<=25, INDEX ), INDEX )


Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago
Anonymous
Not applicable
Author

Hi Thiago,

I came up with the same result. I tried adding the measure as a dimension and formatting it using the 'money' or the 'num' fuctions. and until I get a better answer this way will satisfy my needs,

thanks