Hi,
I have a report where I need to count consecutive days worked by employee. I have a running count of the days, however, I need to reset the count when the dates are not consecutive.
For Example:
I need to count the days, but I need it to reset after 01/11/13, since 01/12 and 01/13 were not worked.
So, the count should be as follows:
Dates:
01/07/13 - 1
01/08/13 - 2
01/09/13 - 3
01/10/13 - 4
01/11/13 - 5
01/14/13 - 1
01/15/13 - 2
01/16/13 - 3
01/17/13 - 4
01/18/13 - 5
Can someone provide the correct syntax to count the consecutive days? Any assistance is greatly appreciated! Thank you!
I have a report where I need to count consecutive days worked by employee. I have a running count of the days, however, I need to reset the count when the dates are not consecutive.
For Example:
I need to count the days, but I need it to reset after 01/11/13, since 01/12 and 01/13 were not worked.
So, the count should be as follows:
Dates:
01/07/13 - 1
01/08/13 - 2
01/09/13 - 3
01/10/13 - 4
01/11/13 - 5
01/14/13 - 1
01/15/13 - 2
01/16/13 - 3
01/17/13 - 4
01/18/13 - 5
Can someone provide the correct syntax to count the consecutive days? Any assistance is greatly appreciated! Thank you!