Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I want to calculate the number of days selected from Date picker, like how many week days during the time range, and how many weekend or holidays in during the time range. Is this possible?
Perhaps like this:
Number of days in the range : count(distinct MyDateFieldHere)
Numner of weeks: the above divided by seven
Number of weekends: count({<MyDateFieldHere={"=WeekDay(MyDateFieldHere)>5"}>}distinct MyDateFieldHere)
Number of Holidays: for that you need to specify which days should be counted as holidays. The best solution is to do this in the load script by creating a Calendar dimension. Here's an example: https://community.qlik.com/t5/Documents/Master-Calendar-with-Working-days-Holidays-Flag/ta-p/1494162