Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
akar_0308
Contributor II
Contributor II

Rank on SubTotal with respect to Grand total

Hello ,

 

Could you please help to get a rank like for Example

Country -France , Rank of City would be Paris = 1,Lyon=2, Nice=3

but SubTotal rank would be 2 as it is 29.49% according to Grand total.

I have attached the document

akar_0308_0-1605702154699.png

 

Labels (1)
1 Solution

Accepted Solutions
MayilVahanan

Hi @akar_0308 

Try like below

If(RowNo()=0, Aggr(Rank(Sum(TOTAL<Country> [Count of Sales])), Country), Aggr(Rank(Sum( [Count of Sales]),4,1),Country, City))

output:

MayilVahanan_0-1605774493752.png

 

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.

View solution in original post

1 Reply
MayilVahanan

Hi @akar_0308 

Try like below

If(RowNo()=0, Aggr(Rank(Sum(TOTAL<Country> [Count of Sales])), Country), Aggr(Rank(Sum( [Count of Sales]),4,1),Country, City))

output:

MayilVahanan_0-1605774493752.png

 

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.