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: 
ganeshreddy
Creator III
Creator III

Can not use date function in set expression ?

Hi All,

I have a date field by the name DTM in my app, on searching for a particular date in list box i am able to find the field only after using '*' as shown in the attached.dates.jpg

I am using this field in a set expression and it is not returning values for matching DTM field value.

= Only({1< DTM = {"$(=vCurrentDt)"} >} Month)


so i decided to change the format of the field to date and that is providing error in expression.


= Only({1< date(DTM) = {"$(=vCurrentDt)"} >} Month)


I there any way that we can achieve this by making changes in application only and not data model.



Thanks,

Ganesh

3 Replies
sunny_talwar

What is vCurrentDt?

ganeshreddy
Creator III
Creator III
Author

Hi Sunny,


The variable expression given below

vCurrentDt=if(GetSelectedCount(WorkingWeek2)=1,date#(date(WorkingWeek2+5),'M/D/YYYY'),num(Today()))

sunny_talwar

Not entirely sure, but may be this

=Only({1<DTM = {"=DTM = vCurrentDt"}>} Month)

OR

=Only({1<DTM = {"=DTM = $(vCurrentDt)"}>} Month)