I am trying to work out the formula so I can count the number of employees that have started on or before the start date in column B, and have left on or after (or still employed, so blank) in column C for every month from June 2023 to June 2024 inclusive.
So for June 2023, 6 employees (Employees, 1 2 7 8 9 & 10) started on or before 1 June 2023, and were active on 30 June 2023 or after.
EmployeeID | Hire Date | Termination Date |
Employee1 | 06/02/2023 | |
Employee2 | 03/01/2023 | |
Employee3 | 03/07/2023 | |
Employee4 | 10/06/2024 | |
Employee5 | 03/10/2022 | 19/10/2022 |
Employee6 | 04/11/2020 | 05/08/2022 |
Employee7 | 01/09/2022 | 09/05/2024 |
Employee8 | 10/10/2022 | 11/08/2023 |
Employee9 | 08/06/2022 | 22/12/2023 |
Employee10 | 04/07/2022 | 11/09/2023 |
So for June 2023, 6 employees (Employees, 1 2 7 8 9 & 10) started on or before 1 June 2023, and were active on 30 June 2023 or after.