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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help Please

Hi All,

I Have an example of a Table like below:

PersonParcelStatus
115
1210
1312
242
254
2610
2710
28

15

391
3105
3116
31210
31315

I Need to see if the last Parcel (Per Person) has a Status of  '15'. Here I use Max(Parcel), but I need to get all the Parcels Prior to it that has a Status of '10'...

My Answer should look like this and should be in a Table (Straight or Pivot):

PersonParcelStatus
2610
2710
31210

Any Advice Please?

6 Replies
Not applicable
Author

Anyone know how to do this?

jonathandienst
Partner - Champion III
Partner - Champion III

Hi

Use

     =FirstSortedValue(Person, -Status)

     =FirstSortedValue(Parcel, -Status)

Regards

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
tresesco
MVP
MVP

Actually, the logic of calculation is not very clear to me. Why should not there be one following row?

PersonParcelStatus
1210
Not applicable
Author

Tresesco,

Because I need all the parcels Prior to the Max(Parcels) with a Status 15 that has a Status of 10.

And Jonathan, This does not seem to work .

See attached example

tresesco
MVP
MVP

I guess you have to use set analysis with p().

Not applicable
Author

Hi , Please find the attached file. I added the FLAG in the script level as 1 for person who reached the Max(Status) else 0.