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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
braeuleinfreu
Contributor
Contributor

Nested Set Analysis with max()

My User_ID has several images and with this piece of code I receive the larges IMAGE_NR. 

      max({$<USER_ID = {'8638087'}> } IMAGE_NR) 

Every image number is linked to an IMAGE_ID. How do I get this?

 

In words:

Give me IMAGE_ID where IMAGE_NR =  max({$<USER_ID = {'8638087'}> } IMAGE_NR) 

 

I tried following that doesn't work:

      sum({$<max({<USER_ID={'8638087'}> } IMAGE_NR)>} IMAGE_ID)

 

Thank you for any thoughts!

Labels (3)
1 Solution

Accepted Solutions
Vegar
MVP
MVP

You could try this expression a try:

only( {< IMAGE_NR = {$(=max({$<USER_ID = {'8638087'}> } IMAGE_NR))} >} IMAGE_ID)

 

View solution in original post

1 Reply
Vegar
MVP
MVP

You could try this expression a try:

only( {< IMAGE_NR = {$(=max({$<USER_ID = {'8638087'}> } IMAGE_NR))} >} IMAGE_ID)