Query date (1 Viewer)

Number11

Member
Local time
Today, 12:14
Joined
Jan 29, 2020
Messages
607
Hi,

So I currently have a query that looks at a table with appointment requests against a another table Appointment Booked and then another Table Appointments completed.


What I need to do is only show appointment requests if the Appointment Booked and Appointment completed dates are greater than the Appointment Request date

So if an appointment was requested on 01.05.2020 but the Appointment Booked has an appointment date for 14.04.2020 and Appointment completed 15.04.2020 this would show records as it was created after the other dates?
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Today, 20:14
Joined
May 7, 2009
Messages
19,175
what common field do you have for each table? appointmentRef, appointmentID, etc.

you join your tables on that field on the query with the condition that you havr.
 

bob fitz

AWF VIP
Local time
Today, 12:14
Joined
May 23, 2011
Messages
4,717
Try:
>[Appointment Request]

as the criteria for "Appointment Booked" column and the "Appointment completed" column
 

Number11

Member
Local time
Today, 12:14
Joined
Jan 29, 2020
Messages
607
what common field do you have for each table? appointmentRef, appointmentID, etc.

you join your tables on that field on the query with the condition that you havr.

"Customer Ref Number"
 

Number11

Member
Local time
Today, 12:14
Joined
Jan 29, 2020
Messages
607
So i have the query linked by the "Customer Ref Number" with criteria "is not null" - this bring me a list of all appointment requested not booked and not completed, but if an appointment completed was before the new requested appointment, this query currently does not show the new appointment requested as its been removed due to the older completed appointment
 

Users who are viewing this thread

Top Bottom