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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
yipchunyu
Creator
Creator

Simple set analysis with less than

Just want to prepare an expression to sum up the value for 2018 Jan-Nov.

There are some fields with the data 

Trans_Date_M = 1,2,3,4,5,6 ....

Trans_Date_MM = 01,02,03,04 ....

Tried several ways but not ok.

sum({<Trans_Date_YYYY={'2018'}, Trans_Date_M={'<= 12'}>} Amount)

sum({<Trans_Date_YYYY={'2018'}, Trans_Date_M={*} - {12}>} Amount)

Any help?

5 Replies
shreya_nadkarni
Partner - Creator
Partner - Creator

Hi,

You could try this

sum({<Trans_Date_YYYY={'2018'},Trans_Date_M ={"<=$(=12)"}>} Amount)

Thanks,

Shreya

jonathandienst
Partner - Champion III
Partner - Champion III

That would include December. Try this:
sum({<Trans_Date_YYYY={'2018'}, Trans_Date_M={"<12"}>} Amount)
Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
yipchunyu
Creator
Creator
Author

Sorry, tried but not work for me.
Total
sum(USD)
Jan -Nov
sum({<Trans_Date_YYYY={'2018'}, Trans_Date_M={"<=$(=12)"}>} USD)
Dec
sum({<Trans_Date_YYYY={'2018'}, Trans_Date_M={"=$(=12)"}>} USD)

All shows the same no when I select 2018.
Any idea?

 

punitpopli
Specialist
Specialist

Can you try this : 

=sum({<Trans_Date_YYYY={'2018'}, Trans_Date_M-={"12"}>}Value)

yipchunyu
Creator
Creator
Author

Seems incorrect in syntax check.