Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
JoeyPob1214
Contributor II
Contributor II

How to show the largest possible value in a text object?

HI!

How can we show the largest possible value in a text object?

For example:

Customer   | Sales

ABCD            | 500

EFGH            | 700

IJKL               | 300

MNOP           | 1000

 

so the text box should output : MNOP 1000 something like that. But when for example EFGH become 1100 for the next month, the text object will output EFGH 1100 automatically.

Thanks

7 Replies
PrashantSangle

Use FirstSortedValue()

try below
FirstSortedValue(Customer,-Sales)

Regards,
Prashant
Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
Vengatesh
Partner - Creator
Partner - Creator

Try This:
=FirstSortedValue(Customer,Sales,1)&' - '& Max(AGGR(Sum(Sales),Customer))
You Know What To Do.
PrashantSangle

if you want value Value along with customer number
then use
FirstSortedValue(Customer,-Sales)& ' ' & FirstSortedValue(Sales,-Sales)

Regards,
Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
JoeyPob1214
Contributor II
Contributor II
Author

what is the meaning of "-" in the sales? if may I ask?
PrashantSangle

he used '-' just to add additional string between Customer and Sales .
So your final output will look like
EFGH-1700
Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
sergio0592
Specialist III
Specialist III

I think Joey asks for - in your First Sorted Value expression :

FirstSortedValue(Customer,-Sales)& ' ' & FirstSortedValue(Sales,-Sales)

So, here - , it means that the function returns the last (highest) sorted value.

JoeyPob1214
Contributor II
Contributor II
Author

hi, why does the Customer name doesn't show up? Thanks