Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
vijetas42
Specialist
Specialist

Minimum and Maximum date

Hi Team,

I have one data set which have values and dates and also one selection for date

in that i am selecting one date and finding out last 8 weeks date and from that i am getting last 8 weeks dataset

from that i am extracting Peak and bottom value,

=num(max({<DATE={">=$(vPrior8WeekDate)<=$(vCurrentDate)"},TYPE={'ALP'}>}VALUE),'#,##.0')

=num(min({<DATE={">=$(vPrior8WeekDate)<=$(vCurrentDate)"},TYPE={'ALP'}>}VALUE),'#,##.0')


now i want to find date associated to that peak and bottom value.

3 Replies
Peter_Cammaert
Partner - Champion III
Partner - Champion III

Have a look at Chart Aggregation Function FirstSortedValue

You can keep the Set analysis expression and use the sort-weight to find the minimum (by default) or the maximum (negate the sort-weight). The first parameter specifies which corresponding field value to return (in your case a date)

Best,

Peter

vijetas42
Specialist
Specialist
Author

firstsortedvalue is not working in my case for maximum and minimum it is giving me same result

Peter_Cammaert
Partner - Champion III
Partner - Champion III

And why is that? For example, are you using DATE or TYPE as dimensions in your object?