Hello all. I wondered if someone may be able to help me with something I am struggling to do. I have a table to data containing absence dates. I need to be able to work out the people with absences in 4 or more consecutive months. Some absences will span over more than one month so need to be able to calculate based on start and end dates. Each absence is on a different line.
ID Start Date. End Date
1111. 01/01/2019. 12/01/2019
1111. 15/02/2019. 15/02/2019
1111. 20/03/2019. 06/04/2019. (4 consecutive months)
2222. 01/01/2018. 01/01/2018
2222. 09/02/2018. 09/02/2018
2222. 23/03/2018. 30/03/2018
2222. 07/04/2018. 10/04/2018 ( 4 consecutive months)
3333. 10/07/2017. 10/07/2017
3333. 25/08/2017. 26/08/2017
3333. 01/10/2017. 01/10/2017
3333. 04/11/2017. 08/11/2017 ( not consecutive months)
I also need it to be able identify if it is consecutive but across years so if someone is off Nov, Dec, Jan and Feb it counts it as consecutive.
any help would be much appreciated.
dawn
ID Start Date. End Date
1111. 01/01/2019. 12/01/2019
1111. 15/02/2019. 15/02/2019
1111. 20/03/2019. 06/04/2019. (4 consecutive months)
2222. 01/01/2018. 01/01/2018
2222. 09/02/2018. 09/02/2018
2222. 23/03/2018. 30/03/2018
2222. 07/04/2018. 10/04/2018 ( 4 consecutive months)
3333. 10/07/2017. 10/07/2017
3333. 25/08/2017. 26/08/2017
3333. 01/10/2017. 01/10/2017
3333. 04/11/2017. 08/11/2017 ( not consecutive months)
I also need it to be able identify if it is consecutive but across years so if someone is off Nov, Dec, Jan and Feb it counts it as consecutive.
any help would be much appreciated.
dawn