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: 
Not applicable

value from last record- dynamic

Hi all,

I have a table of transaction.

I would like to get the last price for each item, within a dynamic period of time.

e.g.,

if the table is:

Item     Date               Price

x          30-Apr-14          10

y          02-May-14          9

y          15-May-14          8.5

x          17-May-14          12

y          28-May-14          11

x          29-May-14          15

y          02-Jun-14           14   

and the user selects May 2013.

The outcome i'm looking for is:

Item     Last Price

x          15

y          11

How can i achieve this?

Thanks.

3 Replies
Anonymous
Not applicable
Author

Assuming it is a straight table where Item is a dimension, try this:

=FirstSortedValue(Price, -Date)

Not applicable
Author

Michael's suggestion works perfectly. See attached.

Not applicable
Author

Thanks guys,

I'll check it in a few days.