Skip to main content
Announcements
Introducing a new Enhanced File Management feature in Qlik Cloud! GET THE DETAILS!
cancel
Showing results for 
Search instead for 
Did you mean: 
qingkong
Contributor III
Contributor III

Find the maximum value, corresponding dimension

I want to find the maximum qty value of the Country, and the maximum value should return the details of the Country

Let's say the maximum value of Country is 20000, and the corresponding Country is US

 

 

 

Labels (2)
1 Solution

Accepted Solutions
joostvanegmond7
Partner - Creator
Partner - Creator

Although this might be not a GeoAnalytics question, you should use the following formulas: 

For getting the maximum qty value:

=max(aggr(Sum(qty),Country))

 

For getting the corresponding country: 

=FIRSTSORTEDVALUE(Country,-aggr(sum(qty),Country))

View solution in original post

1 Reply
joostvanegmond7
Partner - Creator
Partner - Creator

Although this might be not a GeoAnalytics question, you should use the following formulas: 

For getting the maximum qty value:

=max(aggr(Sum(qty),Country))

 

For getting the corresponding country: 

=FIRSTSORTEDVALUE(Country,-aggr(sum(qty),Country))