4 Replies Latest reply: Dec 18, 2017 3:28 AM by surendra j

# Finding Top5 Products in Qliksense

Hello,

Is there any way to show TOP5 products based on sales in QlikSense?

Like we have Dimension Limits in Qlikview, do we have any option in Qliksense?

Thanks,

Nikhil Garg

• ###### Re: Finding Top5 Products in Qliksense

Same thing; just include a limiatation in ur dimension:

• ###### Re: Finding Top5 Products in Qliksense

In Dimension tab->Limitation->Top , You can specify the number or expression

• ###### Re: Finding Top5 Products in Qliksense

Hi,

try below methods, let's say dimension is Employee and Salary is your fact measure.

Method 1: Using Calculated Dimension

Dimension = Calculated Dimension

=IF(Aggr(Rank(SUM(Salary),4),Employee)<=5,Employee)

Tick Suppress When Value is NULL

Expression = SUM(Salary)

Method 2: Using Set Analysis in Expression

Dimension = Employee

Expression = SUM({<Employee = {"=Rank(SUM(Salary),4)<=5"}>}Salary)

Method 3:  Using Dimension Limit

Dimension = Employee

Expression = SUM(Sales)

Dimension Limits

Select Show only Largest 5 Values

Hope this helps to you

Regards,

Deva

• ###### Re: Finding Top5 Products in Qliksense

some add-on to devarasu

--> If you want to show in Text Box

=CONCAT(IF(Aggr(Rank(SUM(Salary),4),Employee)<=5,Aggr(Employee&CHR(9)&MONEY(SUM(Salary),'#,##0'),Employee)),', '&CHR(10),-Aggr(SUM(Salary),Employee))

-->if you want to restrict by Script itself..

Sample script:

Employee:

[

Employee, Salary

A, 10000

B, 20000

C, 24000

D, 40000

E, 100000

F, 50000

G, 125000

H, 80000

I, 75000

J, 40000

K, 50000

L, 35000

M, 25000

N, 50000

O, 35000

P, 20000

];

NoConcatenate

Temp:

Load Employee, SUM(Salary) as Salary Resident Employee Group By Employee;

NoConcatenate

Final:

First 5

Load Employee, Salary Resident Temp Order By Salary Desc;

Drop Tables Employee, Temp;