
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Summing from daily to weekly
Hi, I am using the following to determine daily the number of people working in a table with the dimension individual dates and it works fine.
count({<JobType-={'Type1'}, [QLIK_locationsDates.Date]={"<$(=Today())"},[QLIK_Jobs.Client]={'XXXX'},Resource-={"*Unassig*", "*Emergen*"}>} distinct Resource))
However, when I change the dimension for weeks, it takes the average for the whole week.
What I wish it to do is sum Monday's value plus Tuesday's value plus.... Sunday's value to get a weekly total.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @MikeJones
It's better you create weekly flags (Week([QLIK_locationsDates.Date]) in backend script and use that Week Flag inside Set analysis (Max Week Flag field).
It will dynamically pick the Weeks on Date selections in Front end.
or, you can try this:
count({<JobType-={'Type1'}, [QLIK_locationsDates.Date]= {">=$(=WeekStart([QLIK_locationsDates.Date]))<=$(=Weekend([QLIK_locationsDates.Date]))"},[QLIK_Jobs.Client]={'XXXX'},Resource-={"*Unassig*", "*Emergen*"}>} distinct Resource))
or,
count({<JobType-={'Type1'}, [QLIK_locationsDates.Date]= {">=$(=WeekStart(Today()))<=$(=Weekend(Today()))"},[QLIK_Jobs.Client]={'XXXX'},Resource-={"*Unassig*", "*Emergen*"}>} distinct Resource))
or,
count({<JobType-={'Type1'}, [QLIK_locationsDates.Date]={">=$(=Today()-7)"},[QLIK_Jobs.Client]={'XXXX'},Resource-={"*Unassig*", "*Emergen*"}>} distinct Resource))
Regards,
Av7eN
