# Check Count of Buildings Until Day 1 of Every Month

1. ## Check Count of Buildings Until Day 1 of Every Month

Hello community!

I have been trying to solve this problem for hours but have not been able to reach the desired result.

What I want to do, is, to determine the amount of Buildings available until the first day of each month. For this, I have to measure how many "first day (i.e. 1/1/2022 - 2/1/2022)" fall within a date range and based on that, add up the amounts of the building that were active on each month of a all applicable years.

There are some buildings that are still available while others are no longer.

I have been trying to reach the result by doing different formulas, so don't pay much attention to what I have accomplished so far

I attach the file for your reference.

Thank you!!

2. ## Re: Check Count of Buildings Until Day 1 of Every Month

Maybe in D3 try:

=YEAR([@[End Date]])-YEAR([@[Start Date]])-IF([@[Start Date]]>DATE(YEAR([@[Start Date]]),MONTH(1&D\$2),1),1,0)+IF(MONTH([@[End Date]])>=MONTH(1&D\$2),1,0)

Copy (don't drag) across.

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1