I am trying (without success) to use either Countifs or Sumproduct to count how many cancellations were made with less than 48 hours notice.
So, here Status = Cancelled and Start Date >= 01/11/2022 and Start Date <= 30/11/22 AND where the difference in start date and start time and cancellation date and cancellation time is less than 48 hours.
In the example below, I would expect the result to be 5.
So, here Status = Cancelled and Start Date >= 01/11/2022 and Start Date <= 30/11/22 AND where the difference in start date and start time and cancellation date and cancellation time is less than 48 hours.
In the example below, I would expect the result to be 5.
Monthly_Dashboard - Peelhouse.xlsm | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
A | B | C | D | E | F | G | H | I | |||
1 | Start Date | Start Time | ID | Status | Cancelled Date | Cancelled Time | Criteria | ||||
2 | 13/10/2022 | 09:00:00 | 2355 | Cancelled | 12/10/2022 | 09:47:34 | 01/11/2022 | ||||
3 | 18/10/2022 | 09:00:00 | 1799 | Completed | 30/11/2022 | ||||||
4 | 21/10/2022 | 09:55:00 | 7791 | Completed | Cancelled | ||||||
5 | 01/11/2022 | 10:00:00 | 7445 | Did not attend | |||||||
6 | 01/11/2022 | 10:00:00 | 147 | Cancelled | 21/07/2022 | 11:06:29 | |||||
7 | 01/11/2022 | 10:00:00 | 490 | Cancelled | 23/10/2022 | 14:49:00 | |||||
8 | 01/11/2022 | 10:25:00 | 537 | Cancelled | 29/10/2022 | 13:03:19 | |||||
9 | 02/11/2022 | 10:30:00 | 7445 | Did not attend | |||||||
10 | 03/11/2022 | 10:30:00 | 6253 | Completed | |||||||
11 | 04/11/2022 | 10:30:00 | 7737 | Cancelled | 04/11/2022 | 09:23:23 | |||||
12 | 05/11/2022 | 11:00:00 | 2854 | Cancelled | 05/11/2022 | 09:41:19 | |||||
13 | 06/11/2022 | 12:15:00 | 510 | Completed | |||||||
14 | 06/11/2022 | 12:30:00 | 7441 | Cancelled | 10/10/2022 | 16:10:49 | |||||
15 | 07/11/2022 | 12:40:00 | 510 | Completed | |||||||
16 | 09/11/2022 | 12:40:00 | 5166 | Cancelled | 09/11/2022 | 09:39:03 | |||||
17 | 11/11/2022 | 14:00:00 | 3166 | Completed | |||||||
18 | 12/11/2022 | 14:30:00 | 5314 | Cancelled | 05/09/2022 | 16:01:31 | |||||
Sheet2 |