Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to find Sales by rank

Hi

I have a Deliver table is there ..

a     b     c     d     Sales

1     x     y     z     100

2     m     n     o     200

3     c     d     e     300

4     i     j     k     500

for this above data,i want to find the rank based on dimension .my data will show like this

I have a Deliver table is there ..

a     b     c     d     Sales  Rank

1     x     y     z     100     1

2     m     n     o    200     2

3     c     d     e     300     3

4     i      j     k      500     4

Can any one please write expression fro this one...

Thans

11 Replies
hic
Former Employee
Former Employee

Rank(Sum(Sales))

HIC

amit_saini
Master III
Master III

Hi Roshan,

Please see the attachment.

Thanks,

AS

Not applicable
Author

Thanks for giving quick reply..

I applied ..but i am getting only '1' for all the sales

hic
Former Employee
Former Employee

You need to post an app if we are to see what has gone wrong. But..

- You need to use it as expression in a chart that has a dimension, e.g. Customer

- You need need to make sure that the argument is numeric, e.g. Sum( Sales )

HIC

senpradip007
Specialist III
Specialist III

PFA.

Note: Dont go with the application name.

senpradip007
Specialist III
Specialist III

Hi

Use this

Rank( TOTAL 1/  Sum(Sales))

sunilkumarqv
Specialist II
Specialist II

use these  into you expression

=Aggr(rank(sum(Sales)),Sales)

sunilkumarqv
Specialist II
Specialist II

like these

sunilkumarqv
Specialist II
Specialist II

Previous post what i mentioned according to sum(sales) if you want output like yours

try these

=Aggr(rank(-sum(Sales)),Sales)

O/P:

a     b     c     d     Sales  Rank

1     x     y     z     100     1

2     m     n     o    200     2

3     c     d     e     300     3

4     i      j     k      500     4