I have scorecard dashboard on qlikview. In my table I have three fields, namely Current score, Previous score and Variance(difference of the previous two columns). I am calculation current and previous score using a similar formula, only difference is the variable that is comparing the dates. My current score is calculated based on set analysis expression having date equal to current date while previous score has date equal to 1 month period back. And it works on month end date. Variable used for current & previous score:
vCurrentDate=num(Date(Current_date, 'D/M/YYYY') )
vCurrentPrevDate=num(Date(Montstart(Current_date)-1 , 'D/M/YYYY') )
The calculation is correct it gives numeric values for 31july 2020 and August 2020. But for my set analysis expression for previous score where I use this variable it doesn't give the value, but if I hard code the date field with date field value it gives the required score.
num is a formatting function, meaning that will show a rounded value while keeping the full decimal value underneath. Could you try using floor instead of num?