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

MTD Expression suddenly not working

I had this MTD expression working for almost a month and suddenly something went wrong and I am unable to figure it out. May be it is something small that I might be missing here.

This is the expression

Sum({<[Year] = {$(=Year(Today()))},[Month]={$(=Month(Today()))}>}Sales)

It Calculates MTD sales

Any suggestion will be helpful. Thanks

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Logic looks fine.  Check the format of the data, make sure that Month(today()) has the same format as field Month.
Or, maybe there are Sales data yet in the current month?  It just started...

View solution in original post

4 Replies
SunilChauhan
Champion
Champion

use below code hope this helps

Sum({<[Year] = {$(=Year(Today()))},[Month]={"<=$(=Month(Today()))"}>}Sales)

Sunil Chauhan
Not applicable
Author

Sunil This is not working..

Anonymous
Not applicable
Author

Logic looks fine.  Check the format of the data, make sure that Month(today()) has the same format as field Month.
Or, maybe there are Sales data yet in the current month?  It just started...

Not applicable
Author

Hi Michael... Thanks for pointing it out. You were right. The feed to my application broke and I had no data for the Month of May. I kept on thinking April and testing that data.

Appreciate your help!!