Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I defined variable vTestTest = tomorrows date (14/06/2017)
Then I put the following measure in 'text' object:
=if($(vTestTest)>today(), 'yes', 'no')
The result is no...
Any ideas why?
Try it without dollar sign expansion
=If(vTestTest > Today(), 'yes', 'no')
Try it without dollar sign expansion
=If(vTestTest > Today(), 'yes', 'no')
Ok, it works:)
But - on Qlik's tutorials it has been said to use variables as $(variable)
Why in this case I have to use without $()? What is the rule?
Seems like your vTestTest is hardcoded to be 14/06/2017... which doesn't need expansion here... in fact when you expand it, performs a divison 14 divided by 06 divided by 2017....
Not an experts on variables, but this
MakeDate(2017, 6, 14) as your variable and then this (with dollar sign expansion)
=If($(vTestTest) > Today(), 'yes', 'no')
Thanks Sunny:)
You're right - it seems that QS sees this variable as 14 div. by 6 div by 2017...
It's strange, because I have used the same variable, in the measure below:
=count({<Completed ={"<=$(vTestTest)"}>} distinct CandidatesID)
And... - it works properly!
What is more - if you remove $() - the formula above will NOT work.
Anyone knows why one time I have to use $() and another time without $()?
To me, variables are very confusing and I barely use them... but may be check this out