Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
qv_testing
Specialist II
Specialist II

Need help?

Hi Community,


How to calculate Top 5 Supplier, based on Qty


Thanks in advance..

2 Replies
MK_QSL
MVP
MVP

1) Create a Straight table

Dimension

Customer

Expression

SUM({<Customer = {"=Rank(SUM(Qty),4)<=5"}>}Qty)

or

2) Create a straight table

Dimension

Customer

Expression

SUM(Qty)

Dimension Limit Tab

Tick Restrict which values are.....

Show Only Largest 5 values

Untick Show Others Option

Or

3)

Create a straight table or pivot table

Calculated Dimension

=IF(Aggr(Rank(SUM(Qty),4),Customer)<=4,Customer)

Tick Suppress When Value is Null

Expression

SUM(Qty)

its_anandrjs

Try with this small example for this

Test:

LOAD * Inline

[

Supplier,Qty

a,10

b,50

c,40

d,30

e,5

f,20

g,4

h,8

i,7

];

And then in straight table

Dimension:- Supplier

Expression:- if(Rank(Sum(Qty),4) <= 5,Sum(Qty))