I have two columns of dates, a start date and an end date. I need a formula to count the number of rows that have a start date before or during a specific month, and rows that have an end date during or after that month. I can't for the life of me figure out how to do this.
For example, let's count date ranges that fall in the month of January. There are six different possibilities, as I figure it, and I need to count four of them.
<tbody>
</tbody>
I've tried doing COUNTIFS combined with an AND and OR function, played with nesting IF with COUNTIF, etc., and I simply can't figure out how to do this. Any help is most appreciated.
BT
For example, let's count date ranges that fall in the month of January. There are six different possibilities, as I figure it, and I need to count four of them.
Start Date | End Date | |
1/15/2019 | 1/20/2019 | Both Dates within the month - COUNT |
12/30/2018 | 2/15/2019 | Start date before, end date after - COUNT |
12/28/2018 | 1/20/2019 | End date within the month - COUNT |
1/13/2018 | 2/15/2019 | Start date within the month - COUNT |
12/20/2018 | 12/31/2018 | Both dates before the month - DON'T COUNT |
2/20/2019 | 3/14/2019 | Both dates after the month - DON'T COUNT |
<tbody>
</tbody>
I've tried doing COUNTIFS combined with an AND and OR function, played with nesting IF with COUNTIF, etc., and I simply can't figure out how to do this. Any help is most appreciated.
BT
Last edited: