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

How to find value (count) for the latest month ?

I want to get latest month's 'Count' from 'Month' column where month is given in below format(YYYYMM):

Month           
201912
201910
202002
202003            

Count
30
20
10
50

3 Replies
martinpohl
Partner - Master
Partner - Master

sum({<Month={$(=max(Month))}>}Count)

Regards

MDC
Contributor
Contributor
Author

Thanks for the reply Martin.

It didn't  work. As the Month column has the data
in 6 digits numeric format where i need to seperate both the year value and month value, and select the maximum of both of those values.

Can you help?

martinpohl
Partner - Master
Partner - Master

Your response I did not understand 202003 is greather than 201912.....

But

sum({<Year={$(=max(Year))}, Month = {$(=max({<Year={$(=max(Year))}>}Month))}>}Count)