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

Set Analysis - need to always get a value for the max month

Expression is this:

Sum({1<YEAR_MONTH={'$(=MaxString(YEAR_MONTH))'},METRIC_NAME={'X'},COMPANY_NAME={'Y'}>}METRIC_QUANTITY)

I want this measure to always be the sum of the value for the most recent month in the data when the conditions X and Y are met.

The above works except that it changes as date selections change.  It needs to remain static.  I'm sure that there is some syntax that I'm missing.

Thanks!

1 Solution

Accepted Solutions
sunny_talwar

Try this:

Sum({1<YEAR_MONTH={'$(=MaxString({1}YEAR_MONTH))'},METRIC_NAME={'X'},COMPANY_NAME={'Y'}>}METRIC_QUANTITY)

View solution in original post

1 Reply
sunny_talwar

Try this:

Sum({1<YEAR_MONTH={'$(=MaxString({1}YEAR_MONTH))'},METRIC_NAME={'X'},COMPANY_NAME={'Y'}>}METRIC_QUANTITY)