Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

expression with year and month

Hi, i have a problem with year.

i need to calculate SALES in December , in the end of the year.

I try to use a lot of expression but qlik don't work.

=sum({<DATA_G={">=$(=yearStart(addmonths(max(DATA_G),-1)))<=$(=yearEnd(addmonths(max(DATA_G),-1)))"}>} SALES)

Thank a lot

2 Replies
kumarnatarajan
Partner - Specialist
Partner - Specialist

Hi,

I think you are looking YTD Data. See below syntax.

Ex: =Sum({$<Date={"<=$(=Max(Date))"},Year={"=$(=Max(Year)"},Quarter=,Month=>}SALES)

Not applicable
Author

try this

Sum({$<Year=, DATA_G={"<=$(=Max(date(DATA_G)))"}>}SALES)