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

set analysis : How to get the max month in a bar chart ? (not the max month selected))

Hi everybody,

I have the list of month that the user can select  based on MMM_YY.

I have to calculate a linear tendancy based on my chart.

I use that expression in my set analysis :

MMM_YY={"$(=max(MMM_YY))"} 

So for example, if  I select October, November, December I will get the data for December

Except that there’s no data for December and later in the bar chart so the max month should be November.

I’ve tried many things but can’t get this November month ?

Any tip ?

2 Replies
Anil_Babu_Samineni

Usually, To get Max Month Data. Perhaps this?

Sum({<MMM_YY = {$(=Max(MMM_YY))}>} If(Sum(Measure)>0, Measure))

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
Anonymous
Not applicable
Author

Does not seem to work as MMM_YY={"$(=max(MMM_YY))"}  gives me the max month selected, and I want the last month that has data in the bar chart.

I've succeed with a variable that had a dimension as a set analysis to get the max month.