Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
renjithpl
Specialist
Specialist

Aggr on rank

Hi All,

I have an input table like below

   

IDCategoryCoinsRank
1ASilver2
1BGold1
1BSilver2
1BBronze3

and I want the output table like below

   

IDCategoryCoinsRank
1ASilver2
1BGold1

Rank is the expression field like aggr(max(Rank), ID, Category)

1 Solution

Accepted Solutions
Chanty4u
MVP
MVP

use FirstStoredValue(Distinct Category,-Rank)

View solution in original post

5 Replies
sunny_talwar

May try this:

Dimensions:

1) ID

2) Category

Expression

1) Min(Rank)

2) FirstSortedValue(Coins, Rank)

Capture.PNG

Chanty4u
MVP
MVP

use FirstStoredValue(Distinct Category,-Rank)

swuehl
MVP
MVP

What do you mean with

"Rank is the expression field like aggr(max(Rank), ID, Category)"


Rank column is a calculated column, but self referencing?

renjithpl
Specialist
Specialist
Author

When I used distinct its showing red line under the expression.

I have used without distinct its giving me the right output.

Thanks

sunny_talwar

Red line doesn't mean anything in this case. It just means that expression editor doesn't understand the syntax, but the expression should still work if you click okay.