Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Arun_Starz
Contributor
Contributor

Max Date and Max Value

Hiii Guys,

 

i want the latest date and latest value of each column.

Thanks in Advance

Arun_Starz_0-1643696327946.png

 

1 Solution

Accepted Solutions
nevopotokcloudinary
Contributor III
Contributor III

Load * Inline [
OrderID,Status,Date
1, 0, 01/06/2022 22:01
1, 1, 01/06/2022 23:01
1, 2, 01/06/2022 23:02
2, 0, 01/07/2022 0:01
2, 1, 01/23/2022 5:00
2, 1, 01/07/2022 9:00
3, 0, 01/07/2022 0:01
3, 1, 01/07/2022 0:02
4, 0, 01/07/2022 1:01
4, 1, 01/07/2022 1:03
];

 

FirstSortedValue(Status,-Num(Date#(Date,'MM/DD/YYYY hh:mm')))

 

 

nevopotokcloudinary_0-1643699681116.png

 

View solution in original post

3 Replies
nevopotokcloudinary
Contributor III
Contributor III

You can use firstsortedvalue function (eg. for Product column Firstsortedvalue(Product,-Date) )

nevopotokcloudinary
Contributor III
Contributor III

Load * Inline [
OrderID,Status,Date
1, 0, 01/06/2022 22:01
1, 1, 01/06/2022 23:01
1, 2, 01/06/2022 23:02
2, 0, 01/07/2022 0:01
2, 1, 01/23/2022 5:00
2, 1, 01/07/2022 9:00
3, 0, 01/07/2022 0:01
3, 1, 01/07/2022 0:02
4, 0, 01/07/2022 1:01
4, 1, 01/07/2022 1:03
];

 

FirstSortedValue(Status,-Num(Date#(Date,'MM/DD/YYYY hh:mm')))

 

 

nevopotokcloudinary_0-1643699681116.png

 

Arun_Starz
Contributor
Contributor
Author

Thanks it worked 😊