Remove duplicates and capture duplicates again and again?

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

Guest

Here is what I'm attempting to do. I have a database of 25,000 that I need to call to. I wish to remove the duplicates (approx. 10,000) and call group one (15,000 names). Then take the duplicate list (of 10,000) that I have carved out and dedupe that list and call them, then take whats left of the duplicates, dedupe them and call them...approximately breaking the list down 10 times

i.e. 25,000 original list
Call List B (the original List A with dupes removed
Call to List C (the original List B with dupes removed
Call to List D (the original List C with dupes removed
etc., etc

Can this be done
Thank
 
Have you tried using Microsoft's built-in "Find Duplicates Query Wizard"

Queries->"New" Butto

Otherwise, you could write SQL like this

List
SELECT Customers.[Customer Name], Customers.[Contact Person], Customers.[Phone
FROM Customer
WHERE (((Customers.[Customer Name]) In (SELECT [Customer Name] FROM [Customers] As Tmp GROUP BY [Customer Name] HAVING Count(*)=1 ))
ORDER BY Customers.[Customer Name]

List
SELECT Customers.[Customer Name], Customers.[Contact Person], Customers.[Phone
FROM Customer
WHERE (((Customers.[Customer Name]) In (SELECT [Customer Name] FROM [Customers] As Tmp GROUP BY [Customer Name] HAVING Count(*)>1 ))
ORDER BY Customers.[Customer Name]

Remember, any record you delete in a query will be deleted in your table. If you want to maintain your original list, use a MakeTable query instead of a Select

Hope this helps

Jim
 
Back
Top