Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I need to get the names of the six top selling Clients. This is easy to do in a chart, but I need each of them as either a variable or a text value.
If you take a look at the attached sample, the chart displays all the values all the time, even when you select a Client. This is exactly what I want to happen. However, I also want it to happen in the text boxes, and those go blank when you have one or more Clients selected.
My statement for the first text box is:
=Aggr(If(Rank(Sum({$<Client=>}Sales))=1, Client), Client)
I would think this should display the #1 Client regardless of what's selected, but it doesn't. Any ideas how I can rewrite it?
If you want the top Client no matter what you select, i.e. always show Chef, try
=only({1<Client = {"=Rank(sum({1}Sales))=1"}>} Client)
Hi Bill,
try
=only({<Client = {"=Rank(sum({<Client>}Sales))=1"}>} Client)
to get your top Client Chef.
Wow, that's great!
But I knew I made my example too simple. In my real app, I've got lots of a couple of other fields that could be selected and I want them ignored too. I'm trying this but it's not quite right:
=only({<Client = {"=Rank(sum({<Client,Product=,Salesperson=>}Sales))=1"}>} Client)
Answered my own question, and no, my stab at it doesn't work. Here's a better sample file. If you go in and select, say, Hats and Phil, it breaks.
Thanks again!
If you want the top Client no matter what you select, i.e. always show Chef, try
=only({1<Client = {"=Rank(sum({1}Sales))=1"}>} Client)
Perfect! I'm not sure why it works, but it does, so I'll have to research it and figure it out.
Thanks so much!