What about if you have duplicates, and none of the records for the customer
have a value of 3?
If you don't want any of those, you could try creating a subquery to
determine all of the duplicate Cust Number, along the lines of:
SELECT [Cust Number]
FROM MyTable
GROUP BY [Cust Number]
HAVING Count([Cust Number]) > 1
Save that query (let's call it qryDuplicates to simplify the discussion),
then create a second query along the lines of:
DELETE FROM MyTable
WHERE [Cust Number] IN (SELECT [Cust Number] FROM qryDuplicates)
AND TheOtherField <> 3
--
Doug Steele, Microsoft Access MVP
(no e-mails, please!)
bc said:
I find that I can eliminate duplicates in a table, but I want to be able
to tell Access which records to keep as the remaining duplicate. For
example, I have a Field called Cust Number that has many duplicates that I
want to wittle down so that a customer is not listed twice. But I want the
customers remaining to be associated with another Field with a specific
value (number) in it. I want it to keep all customers that also have a
value of "3" in another field in the record.