I have a table with structure
i need to display only the name which processed maximum number of invoices in a text object
Thanks in advance
Not for that data I am using some other and data and found the average of time they are utilizing for processing certain invoices .
and now I need to show the member who is having least average response time (i.e) High Productivity.
= FirstSortedValue( aggr(ModBy,ModBy) , aggr(min((-avg(Diff))),ModBy) )
= FirstSortedValue( aggr(ModBy,ModBy) , aggr( avg(Diff),ModBy) )
FirstSortedValue() will return the min value sorted by your sort weight avg(Diff), if you want to get the max, add the minus sign.
And if you can have multiple ModBy's with the same min sort weight, FirstSortedValue won't return anything, to get at least one, add a DISTINCT qualifier:
= FirstSortedValue(DISTINCT aggr(ModBy,ModBy), aggr( avg(Diff),ModBy) )