Deleting Records in comparison

J

Jack

Hello,

I have two spreadsheets (Main and New) in Excel. I've imported them both
into Access. I would like to compare the two tables (Main and New) and
eliminate any records in New that match records in Main. This would leave me
with only records in New that do not appear in Main.

I've tried a delete query, but I can't seem to nail down how to set it up.

Thanks for your help, in advance,

Jack
 
L

lljo40

Use the Query wizard to create a Find Duplicates Query.

Then use a delete query, that links to the records in this query, so it
will only delete the records from New that match the Duplicates.
 
D

Dirk Goldgar

Jack said:
Hello,

I have two spreadsheets (Main and New) in Excel. I've imported them
both into Access. I would like to compare the two tables (Main and
New) and eliminate any records in New that match records in Main.
This would leave me with only records in New that do not appear in
Main.

I've tried a delete query, but I can't seem to nail down how to set
it up.

Thanks for your help, in advance,

Jack

On what fields would you be comparing the two tables? What constitutes
a duplicate record? If you create a query (in design view) that
inner-joins the two tables on the comparison fields, and drag the "*"
from the New table to the field grid, and then turn that query into a
Delete query, running that query should delete the duplicate records in
New.
 
Top