Filter records be initial appointment type but then include all subsequent entries (1 Viewer)

gojets1721

Registered User.
Local time
Today, 16:37
Joined
Jun 11, 2019
Messages
429
Apologies for the likely confusing title. I've included an example database.

Essentially, I'm looking to create a query that filters down to all 'inspection' appointment types, but also includes any subsequent appointments regardless of type. So if the customer had a different appointment type after the inspection, those would be included in the query too.

Please let me know if I didn't explain it well enough. I'm basically trying to query down to additional appts that could have been triggered from an inspection (in my actual database)

Thanks
 

Attachments

  • Example01.accdb
    516 KB · Views: 409

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 07:37
Joined
May 7, 2009
Messages
19,169
Union Query?
 

plog

Banishment Pending
Local time
Today, 18:37
Joined
May 11, 2011
Messages
11,613
Build a query to find the first Inspection date for each CustomerID. Then build another query using that query and your table to pull all the records of those customers that occured after their first inspection date.
 

gojets1721

Registered User.
Local time
Today, 16:37
Joined
Jun 11, 2019
Messages
429
So I created a query to find the first inspection date. I'm not sure how to do the second part too in regard to using that query with the original table to find the other appts tho
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 07:37
Joined
May 7, 2009
Messages
19,169
see Query1.
 

Attachments

  • Example01.accdb
    516 KB · Views: 258

plog

Banishment Pending
Local time
Today, 18:37
Joined
May 11, 2011
Messages
11,613
What does your first query look like? Post the SQL or another database.
 

arnelgp

..forever waiting... waiting for jellybean!
Local time
Tomorrow, 07:37
Joined
May 7, 2009
Messages
19,169
See also Query2.
 

Attachments

  • Example01.accdb
    516 KB · Views: 403

Users who are viewing this thread

Top Bottom