4 Replies Latest reply: Aug 11, 2017 4:21 AM by Liv ma RSS

    How to return the field value corresponding to a calculation

    Liv ma

      Hello people, would appreciate your help

       

      Suppose I have a data structure which contains just 3 fields: Client, Region and Sales

       

      I want to display, using a single formula, the Region with the highest sales

       

      I now how to calculate the sales of the Region with the highest sales:

       

      max(aggr(sum(Sales),Region))

       

      but how can I also display the Region that the above value corresponds to?

       

      of course I can do this using a simple table with region and sales with a limitation set to 1 in the dimension field, but I need to insert this information in the title of a gauge

       

      your help is much appreciated

       

      thank you