Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
How to sort the rank?
ex:
I have some data in straight table like:
Group | Name | sum(amount) | Rank(sum(amount)) |
---|---|---|---|
A | AA | 500 | 3 |
A | CC | 200 | 5 |
B | BB | 800 | 1 |
B | AA | 600 | 2 |
C | BB | 300 | 4 |
C | DD | 100 | 6 |
i want to o/p like this:
group name amount rank
B BB 800 1
...........
C DD 100 6
REGARDS,
Create a Straight Table
Dimension
Group
Name
Expression
SUM(amount)
NUM(Rank(TOTAL SUM(amount),4))
Double click on 2nd expression to do ascending/descending sorting.
Create a Straight Table
Dimension
Group
Name
Expression
SUM(amount)
NUM(Rank(TOTAL SUM(amount),4))
Double click on 2nd expression to do ascending/descending sorting.
Thanks for quick reply.
what is the use that 4. NUM(Rank(TOTAL SUM(amount),4))
IF two SUM(amount) is same then it will give lowest rank on first row and next row will be incremented by one..
say if you have sum(amount) 500 for two Group and Name combination, one will be allocated Rank 5 and 2nd by 6
I am nt getting correct ranks..can you plz check.
find the sample app.
Like this?
Also you can use this... for total Rank
NUM(RANK(TOTAL SUM(Amount),4))