I am trying to make a formula in smartsheets where I can check availability. We have a current schedule that consists of events where a trailer is booked out between dates. I have formula that will give me the daily count of how many trailers are booked on a particular day.
=11 - (COUNTIFS([Restroom Trailer]:[Restroom Trailer], "2 Stall Restroom Trailer", [Task Type]:[Task Type], "Long Term Event", [Event (or Job) Start Date]:[Event (or Job) Start Date], @cell <= [Event (or Job) Start Date]@row, [Event (or job) End Date]:[Event (or job) End Date], @cell >= [Event (or Job) Start Date]@row)) - (COUNTIFS([Restroom Trailer]:[Restroom Trailer], "2 Stall Restroom Trailer", [Event (or Job) Start Date]:[Event (or Job) Start Date], AND(@cell >= [Event (or Job) Start Date]@row, @cell <= [Event (or Job) Start Date]@row), [Task Type]:[Task Type], "Event"))
What I'm trying to figure out is how to plug in an example date range to check availability on particular trailer sizes. Viewing this as a gantt does not work well. I have created a report to try and view this with no success either. Using filters has not quite given me what I need either. Although a combination of these could work in some way.
Basically I want to input a range of two dates and have it spit out the number of trailers available during those two dates based on what is already booked.
Does anyone have a formula that calculates availability based off existing events booked?