I am using Rank function in my expression. Below is the table, where I am ranking Count(Accounts) for each person and showing the table. However, I need to consider Date while calculating the Rank function. For the same #Accounts, I need to consider the Min Date having lowest Rank. For Ex: BBB, CCC and DDD is having same #Accounts of 6 but the rank should consider the Date order while calculating. So BBB should be 2, CCC should be 3 and DDD should be 4. How to achieve that?
Current Rank Expression: Rank(Count(Distinct Accounts),4,0) and I kept number format.
@Kushal_Chawda Firstly, I need the expression at chart level as already I have written Rank function in the Chart
Secondly, The rank should be based on the highest Accounts for each Name and for the Same count accounts, the rank should be considering the date order. So, the Name having 4 accounts will be ranked at 10 and 11 positions only but again the 10 position should be "KKK" because he has min date value compared to "LLL".
I hope this clarifies your question.
@polisetti I tried below
With Date and Name in dimension put below expression
I have assumed that # account is the measure you can replace it with your actual measure in place of highlighted one.
=num(rank(total sum([# Accounts]),4)) // for rank
= sum([# Accounts]) // #account
Sort order is
1) #account -> Numeric desending
2) Date -> Numeric ascending