Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have below data and want to achieve ranking, but it gives me different way.
PROD Sales Rank
A 12 1
B 10 2
C 8 3-4
D 8 3-4
I am expecting Ranks should be 1,2,3,4, how to achieve this.
Thanks,
Hello,
I believe you're using this expression: rank(sum(Sales)).
Try this one instead to get the result you want (sequential ranking): num(rank(sum(Sales), 4))
I also suggest you check under QlikView help the below topic for examples and detailed explanation:
Examples of Chart Ranking Functions
for Rank column use expression rank(....., 4)
and format expression in Number tab as Integer
jp above is correct above. The joker here may well have been that rank() returns a dual value, compare these two expressions where the num() & text() show the two different dual representations :
num(rank(sum(Value), 4))
text(rank(sum(Value), 4))
Hi,
Use this expression for Rank
=Aggr(Num(Rank(Sum(Sales),4,1)),PROD)
It's working
Regards,
Vivek