I've gone through other posts regarding date diffs & calculated # weekdays & assigning next valid work days (many thanks!), but I don't see something quite like what I need.
I am trying to create a way to generate a schedule of begin and end dates for sequential tasks on a job, each of which have some assigned # of days, beginning with a given date and excluding weekend dates. So for job "x" starting on Friday, 11/01 I need:
Have | Have | calculated Have | calculated Have | Need | Need | |||||
Task # | # days | start day | stop day | Begin Date | End Date | Excludes weekends | ||||
1 | 1 | 1 | 1 | 11/1/2019 | 11/1/2019 | |||||
2 | 3 | 2 | 4 | 11/4/2019 | 11/6/2019 | 11/2-3 | ||||
3 | 1 | 5 | 5 | 11/7/2019 | 11/7/2019 | |||||
4 | 4 | 6 | 9 | 11/8/2019 | 11/13/2019 | 11/9-10 | ||||
5 | 4 | 10 | 13 | 11/14/2019 | 11/19/2019 | 11/16-17 | ||||
6 | 3 | 14 | 16 | 11/20/2019 | 11/22/2019 |
I can get the begin and end dates I need within first scheduled week (accommodating 1 weekend) with given calculated start/stop DateAdds, but then I hit a roadblock in trying to accommodate multiple weekends which may be incorporated into the overall job schedule.
Any tips?
Thanks!
Solved! Go to Solution.
Hi @v-monli-msft ,
I ended up taking a different approach to the problem. Rather than try to work out some convoluted calculation, I made a SQL table of calendar dates excluding weekends and used that to pull in start/stop dates.
Thanks for the response though!
Hi @lknudson1 ,
Can you please explain your requirement with sample data?
Regards,
Mona
Hi @v-monli-msft ,
I ended up taking a different approach to the problem. Rather than try to work out some convoluted calculation, I made a SQL table of calendar dates excluding weekends and used that to pull in start/stop dates.
Thanks for the response though!
User | Count |
---|---|
194 | |
126 | |
90 | |
48 | |
44 |
User | Count |
---|---|
280 | |
160 | |
138 | |
81 | |
76 |