Subject Re: [ib-support] Sql Query
Author Woody
From: "Svein Erling Tysvær" <svein.erling.tysvaer@...>
Sent: Thursday, August 02, 2001 10:16 AM
> 2) The query only checks those records where the room_type is
> reserved/checked in for parts of the stay. I think you can get away with
> two checks, though:
>
> a) When a reservation has arrival < :arrival and departure > :arrival
> b) When a reservation has arrival > :arrival and arrival < :departure
>

Almost. You forgot to check if the departure date also is between the dates.

c) When a reservation has departure between :arrival and :departure

Woody