A
Ange Kappas
Hi,
As you can see below I have a query which includes records from the
reservation table, but I want to show only those records which their arrival
date ARRIVAL of the RESERVATIONS table is equal to the value of RUNDAY in
the HOUSEKEEPING DATA Query.
SELECT ROOMS.ROOMS, [HOUSEKEEPING DATA].HOTELAPT, [HOUSEKEEPING
DATA].PERSONS, [HOUSEKEEPING DATA].RESNAME, [HOUSEKEEPING DATA].ARRIVAL,
[HOUSEKEEPING DATA].DEPARTURE, [HOUSEKEEPING DATA].TOWELS, [HOUSEKEEPING
DATA].[TOWELS NEXT], [HOUSEKEEPING DATA].LINEN, [HOUSEKEEPING DATA].[LINEN
NEXT], [HOUSEKEEPING DATA].RUNDAY, RESERVATIONS.PERSONS,
RESERVATIONS.RESNAME, RESERVATIONS.COMPANY, RESERVATIONS.ARRIVAL
FROM (ROOMS LEFT JOIN [HOUSEKEEPING DATA] ON ROOMS.ROOMS = [HOUSEKEEPING
DATA].ROOMNO) LEFT JOIN RESERVATIONS ON ROOMS.ROOMS = RESERVATIONS.ROOMNO
GROUP BY ROOMS.ROOMS, [HOUSEKEEPING DATA].HOTELAPT, [HOUSEKEEPING
DATA].PERSONS, [HOUSEKEEPING DATA].RESNAME, [HOUSEKEEPING DATA].ARRIVAL,
[HOUSEKEEPING DATA].DEPARTURE, [HOUSEKEEPING DATA].TOWELS, [HOUSEKEEPING
DATA].[TOWELS NEXT], [HOUSEKEEPING DATA].LINEN, [HOUSEKEEPING DATA].[LINEN
NEXT], [HOUSEKEEPING DATA].RUNDAY, [HOUSEKEEPING DATA].ROOMNO,
RESERVATIONS.PERSONS, RESERVATIONS.RESNAME, RESERVATIONS.COMPANY,
RESERVATIONS.ARRIVAL;
Thanks
Ange
As you can see below I have a query which includes records from the
reservation table, but I want to show only those records which their arrival
date ARRIVAL of the RESERVATIONS table is equal to the value of RUNDAY in
the HOUSEKEEPING DATA Query.
SELECT ROOMS.ROOMS, [HOUSEKEEPING DATA].HOTELAPT, [HOUSEKEEPING
DATA].PERSONS, [HOUSEKEEPING DATA].RESNAME, [HOUSEKEEPING DATA].ARRIVAL,
[HOUSEKEEPING DATA].DEPARTURE, [HOUSEKEEPING DATA].TOWELS, [HOUSEKEEPING
DATA].[TOWELS NEXT], [HOUSEKEEPING DATA].LINEN, [HOUSEKEEPING DATA].[LINEN
NEXT], [HOUSEKEEPING DATA].RUNDAY, RESERVATIONS.PERSONS,
RESERVATIONS.RESNAME, RESERVATIONS.COMPANY, RESERVATIONS.ARRIVAL
FROM (ROOMS LEFT JOIN [HOUSEKEEPING DATA] ON ROOMS.ROOMS = [HOUSEKEEPING
DATA].ROOMNO) LEFT JOIN RESERVATIONS ON ROOMS.ROOMS = RESERVATIONS.ROOMNO
GROUP BY ROOMS.ROOMS, [HOUSEKEEPING DATA].HOTELAPT, [HOUSEKEEPING
DATA].PERSONS, [HOUSEKEEPING DATA].RESNAME, [HOUSEKEEPING DATA].ARRIVAL,
[HOUSEKEEPING DATA].DEPARTURE, [HOUSEKEEPING DATA].TOWELS, [HOUSEKEEPING
DATA].[TOWELS NEXT], [HOUSEKEEPING DATA].LINEN, [HOUSEKEEPING DATA].[LINEN
NEXT], [HOUSEKEEPING DATA].RUNDAY, [HOUSEKEEPING DATA].ROOMNO,
RESERVATIONS.PERSONS, RESERVATIONS.RESNAME, RESERVATIONS.COMPANY,
RESERVATIONS.ARRIVAL;
Thanks
Ange