Eliminating Duplicate records

A

Amin

So I importing a text document that will have some duplicate records. There
are about 12 fields in the table. Is there a simple way to delete the
duplicate records?

If not, I have two fields that both of them should never be the same for any
two records, the Create Time and the Event Time. Could I use this to delete
one of the duplicates?

Thanks for any suggestions!
Amin
 
D

Danny Lesandrini

The easiest way is to create a clone of the table with no data. (Ctl+C and
Ctl+V)
Set the table Primary Key as the combination of fields that define a unique
record.
Copy and paste all the records from the original table into this one.

The duplicates will be rejected and not inserted.
 
A

Amin

Thanks Danny,

I was looking for more along the lines of a DELETE query or an import
specification, that I can use as a Macros to run every day (I have to
download the data every day from a very old-school database program). Thanks
to this community, and some books, I am fairly adept with SQL now, but I
don't know how to check records against other records.

Could I set the primary key as the combination in the Import specs?

Thanks,
Amin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top