Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Not applicable

Using variables to create date range in set analysis

I am currently trying to create a date range filter in QlikSense using set analysis and the qsVariable extension, however I am having trouble in getting this to work.

Initially I was trying:




    StatusFlagCode = {$(vStatusFlag)}


This seemed fairly logical to me, but returned zero results. After some investigation it was suggested that I try the following:




    StatusFlagCode = {$(vStatusFlag)}


Unfortunately this also does not work, and it appears that the variable is not recognized within, as it in enclosed within quotation marks:


Any suggestions would be appreciated!


1 Reply
Not applicable

Re: Using variables to create date range in set analysis

So it looks like the following works in this situation:

[PP.PaymentReceivedDate.autoCalendar.Date]={"$(= '>=' & date(vFrom) & '<=' & date(vTo))"},

The script editor still doesn't highlight the variables here, but it works in practice!