Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
I have three dimension in my pivot, Country, city and Week.
I have to show top 4 city and remaining as Others, in each country by bookings(sorting based on total bookings) and there weekly sales.
I used below calculated field for city(second dimension.
=aggr(if(rank(sum(Bookings))<=5,city,'Others'),country,city)
This gets me correct results, but I want to sort it by first city in descending bookings then Others.
How can we achieve this?
= aggr(if(num(rank(sum(Bookings),4))<=5,city,'Others'),country,city)
or
= if(aggr(num(rank(sum(Bookings),4)),country,city)<=5,city,'Others')