Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hii,
In the script, I declare my variable vMoins6mois
and in the set analysis I want to count idAP that has a date lower than the declared variable
but it's not okay ...
I use Qlik Sense Enterprise September 2018 SR2
Thanks for help
Clem
First remove the = character from your measure expression.
And please post expressions as text instead of as screenshots. It's darn hard to copy text from images.
Sorry, I removed = character like that
count({$<dateAPAC={"<$(vMoins6mois)"}>}distinct idAP) but it doesn't work.
For example vMoins6mois=date(Date-183,'DD/MM/YYYY')
I select 2018 october 1st with Date filter, so vMoins6mois= 2018 april 1st and I want to count idAP before this date.
The current result is 0... although there are idAP with a lower date
the expression you have in the variable is "Date-183" a reference to a field in your data model or another variable?
I'm going to assume it is a field.
The first thing I would do is to make sure the date fields in your data are stored in the default qlik date format, an easy way to do this is to load the date fields within Date(Num(Field)). Then when you do your search in Set analysis you don't get messed up by weird date formatting problems.
Then I would build you Set Analysis in layers...
I think my third example is probably the one that will work for you