
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Working days and filter
Hi.
I am trying to use the networkdays function to get the number of days in a month. I have a filter called SchMonth that lists the months as Jan, Feb etc. I have tried using the expression below to get the number of days when a month is selected in the filter SchMonth but it does not give the number of days for the month ie selecting Feb in SchMonth does not give the correct number of working days ie 20
=NetWorkDays(MonthStart(SchMonth),MonthEnd(SchMonth))
Thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
MonthStart and MonthEnd require an actual date as input, not just a month.
In case you got a Date-field as well, you can try using that.
If you don't, and you have a Year-field, try the following:
=networkdays( monthstart(makedate(Year, Month)), monthend(makedate(Year, Month)) )

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You're welcome.
If you managed to resolve your question, mark it as such, even if it's your own answer.
So no resolved questions stay lingering around with an unresolved marker on them.
Thanks!
Regards,
Tim P.


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
you can check how to use function here https://help.qlik.com/en-US/sense/September2018/Subsystems/Hub/Content/Sense_Hub/Scripting/DateAndTi...
Does your field SchMonth has number format or is it just text (did you get month name by using Month() function)? The other thing is that you not define holidays dates.
