Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
 shekhar_analyti
		
			shekhar_analyti
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi All ,
max(aggr(sum(Sales),Country))
Above expression gives me max of sale (aggregated range) . But i want to display the country in a text box , which is having max sales (using above expression) , . Please help me with the expression .
Also the expression for second highest and third highest country in separate text box . Need help on the expression .
I have attached data as well .
Thanks & Regards
Shekar
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		For 2nd and 3rd highest, you can use this
2nd highest
FirstSortedValue(Country, -Aggr(Sum(Sales), Country), 2)
3rd highest
FirstSortedValue(Country, -Aggr(Sum(Sales), Country), 3)
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try this
FirstSortedValue(Country, -Aggr(Sum(Sales), Country))
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		For 2nd and 3rd highest, you can use this
2nd highest
FirstSortedValue(Country, -Aggr(Sum(Sales), Country), 2)
3rd highest
FirstSortedValue(Country, -Aggr(Sum(Sales), Country), 3)
