Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Easy (?) KPI Question

This is probably a really easy question for someone who isn't a novice with QlikSense, but I'm trying to do the following, and could use some help.

I have a series of data in a bar chart and a KPI that shows the highest amount in that data. But I also want to display the name associated with that value in a box next to it - either a second KPI or text box. I have been able to do that when only a single name value is selected, but when it's not filtered for a particular person, it shows up blank. Screenshot is attached to give you an idea. In this example, Matt Mawson's name should appear in the box next to the Pts Leader.

1 Solution

Accepted Solutions
sunny_talwar

What is the expression that you are using to create the bar chart? Is it Sum(Points) or Avg(Points)? Assuming it is Sum(Points), try this:

FirstSortedValue(FullName, -Aggr(Sum(Points), FullName))

View solution in original post

4 Replies
sunny_talwar

You should be able to use FirstSortedValue() function here, not sure what you expression is, but something like this:

FirstSortedValue(Name, -Aggr(YourBarChartExpression, Name))

Not applicable
Author

Thanks Sunny. It didn't quite work, but I may be interpreting your note incorrectly. This is the expression I just created, but it's returning an error:

FirstSortedValue(FullName,-Aggr(Max(Points),FullName)

with "FullName" being the name field I want to return and Points being the Max value in the KPI to the right. When you say "YourBarChartExpression", I wasn't sure what I should replace that with.

sunny_talwar

What is the expression that you are using to create the bar chart? Is it Sum(Points) or Avg(Points)? Assuming it is Sum(Points), try this:

FirstSortedValue(FullName, -Aggr(Sum(Points), FullName))

Not applicable
Author

Sunny - you're the best! Thanks so much - that worked!