If I understand you correctly you want to make sure you don't
repeat the email-partno combination?
Lets assume for simplicity that this is in one table and has a field XX
which is the primary key
SELECT * from wherever
where xx in
(select max(xx) from wherever
group by email, partno)
Grouping by email and partno in subquery will insure that you get only one
record for each combination. You wouldnt have to use the max(xx) you could
use min(xx) depending on whether you wanted the earliest record or latest
----- Original Message -----
From: "Ben Densmore" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, December 27, 2001 8:45 AM
Subject: looking for duplicate emails
> Hi everyone,
> can someone possibly tell me the best way to compare email addresses
> that are allready in a database? Some of the info that my company gets
> from customers may come from the same person but looking for 2 different
> part numbers so I need to look for the email address and then compare
> the part numbers and if they are the same the only show one of the
> records, if the part numbers are different then show both.
>
> Thank You,
> Ben Densmore
>
>
______________________________________________________________________
Get Your Own Dedicated Windows 2000 Server
PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
Instant Activation � $99/Month � Free Setup
http://www.pennyhost.com/redirect.cfm?adcode=coldfusionb
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists