Comparing 2 tables, deleting duplicates

A

Andy C Matthews

Please help, I'm tearing my hair out trying to figure this out!
I have two tables. The first is a master list of fields, the second is a
list of fields I need to subtract from it. I can find the duplicates using a
query (43) but when I try to find the PARCELIDs that are not equal using <> i
end up with hundreds of thousands of records, even though the original table
only has around 12,000!
Please help! The values to be compared are called PARCELID and are text.

Andy
 
J

John Spencer

I would suspect that you have a cartesian join (no join line) between the
two tables. So then you get every combination of the records in the two
tables. So if table one has 12,000 records and table two has 100 records,
you are going to end up with 1,200,000 rows in the query minus 100 where the
parcelID are equal.

I would guess that you mean you have a table with records (not a list of
fields) and another table with records that you want to match up to the
first table. Then you want to remove the matching records from the first
table. Is that correct?

If not, try explaining your problem in a bit more detail. How are the
records (not fields) in table one related to the records in table two? If
you have a record in table two, how do you know that it is a match for a
record in table one?

For instance, if the ParcelID in table two is "xyz" then that matches the
ParcelNumber of "xyz" in table one.

Next step, is what do you mean by "subtract"? Do you want to show all
records except those where the ParcelID are the same? Do you want to delete
records from the first table (master)?
 
Top