C
Chad
Hello everyone. I have beed struggling with this for a while but can't seem
to figure it out. I have a database that has two tables with the associated
fields:
tblReservation
- Reservation_ID
- Arrival_Date
- Departure_Date
tblMonth
- Month_ID (1, 2, etc.)
- Month_Desc (Jan, Feb, etc.)
I am trying to develop a query that lists all twelve months and the number
of days associated with that month based on the Arrival and Departure Dates.
For Example:
If a reservation spans from 1/27/08 - 2/3/2008, I would wan tthe query to
return:
Month Days
Jan 5
Feb 3
etc...
I am able to return the correct numbers if the reservation doesn't span more
than one month, but I am not sure of the best way to return the data as
above. Any help would be greatly appreciated.
Thanks!
Chad
to figure it out. I have a database that has two tables with the associated
fields:
tblReservation
- Reservation_ID
- Arrival_Date
- Departure_Date
tblMonth
- Month_ID (1, 2, etc.)
- Month_Desc (Jan, Feb, etc.)
I am trying to develop a query that lists all twelve months and the number
of days associated with that month based on the Arrival and Departure Dates.
For Example:
If a reservation spans from 1/27/08 - 2/3/2008, I would wan tthe query to
return:
Month Days
Jan 5
Feb 3
etc...
I am able to return the correct numbers if the reservation doesn't span more
than one month, but I am not sure of the best way to return the data as
above. Any help would be greatly appreciated.
Thanks!
Chad