excluding records

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have one table with invoice numbers. Another table represents invoices
that have already run and also has invoice numbers. I need a query to pull
only records from the first table that are NOT in the second table. I do not
know sql, so I need a solution I can do in the query design screen or
expression builder, etc. Thanks...
--
Regards,

Bryan Brassell
Padgett Business Services
281-897-9141
 
Bryan

Access comes with an "unmatched" query wizard. You can use that you help
you build your query.

Jeff Boyce
<Office/Access MVP>
 
I have one table with invoice numbers. Another table represents invoices
that have already run and also has invoice numbers. I need a query to pull
only records from the first table that are NOT in the second table. I do not
know sql, so I need a solution I can do in the query design screen or
expression builder, etc. Thanks...

The "Unmatched Query Wizard" will build this for you.

If you want to "roll your own", create a new Query by adding both
tables to the query grid; join them by the invoice number field.
Select the Join line and choose option 2 (or maybe 3) - "Select all
records in <first table> and matching records in <already run table>".

Include whatever fields you want in the report from the first table,
and ONLY the InvoiceID from the second. On the criteria line under
that field put

IS NULL

John W. Vinson[MVP]
 
Back
Top