[UPHPU] Re: Deduping a list
Brandon Stout
hplsbyufan at imapmail.org
Fri Jul 28 18:58:56 MDT 2006
D. Turnbull wrote:
> If both your lists are (or can be) in a database, then I suggest
> running a
> query something like this:
>
> SELECT DISTINCT email_address
> FROM good_email_table
> WHERE email_address NOT IN (
> SELECT DISTINCT email_address
> FROM do_not_email_table)
>
> If you can, let your DBMS do the work - it'll almost always be faster
> than
> doing it w/ PHP.
>
> Dave
Note that you'll need MySQL >= 4.1.x for this since it uses a subquery.
Brandon Stout
http://mscis.org
More information about the UPHPU
mailing list