Qlik Community

Ask a Question

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Announcements
Welcome to our newly redesigned Qlik Community! Read our blog to learn about all the new updates: READ BLOG and REPORTED ISSUES
cancel
Showing results for 
Search instead for 
Did you mean: 
Creator II
Creator II

Find max value within a date range

Hello,

I'm trying to find the max value within a certain date range that I have set dynamically using set analysis.

For example,  in the table below I have a date range, set to go back a certain amount of days based on the max date, along with the individual sums for those days. 

What I'm trying to figure out is how to get the max value for the date range.

   

   

Date7/10/20167/9/20167/8/20167/7/20167/6/20167/5/20167/4/20167/3/2016
individual433232312321452432292444
max452452452452452452452452

Any ideas?

Thank you for your help.

1 Solution

Accepted Solutions

How about this:

Max(TOTAL Aggr(Sum({<YourSetAnalysis>} individual), Date))

View solution in original post

4 Replies

May be like this:

Max(TOTAL {<YourSetAnalysis>} individual)

Here YourSetAnalysis and individual are placeholders and replace them with what you have for set analysis and fieldname, respectively

Creator II
Creator II

Thank you for the reply Sunny.  This is close I feel, however the "individual" values are the result of a SUM function, which doesn't appear to work with MAX before it:

max(total sum({<Set Analysis>} individual))

How about this:

Max(TOTAL Aggr(Sum({<YourSetAnalysis>} individual), Date))

View solution in original post

Creator II
Creator II

That works!! Thank you so much Sunny!!