-----Original Message-----
From: Chip Wiegand [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 11, 2004 3:28 PM
Subject: [PHP-DB] query of two tables returns too many rows, many more
than the two tables contain

I have two tables I want to get out the rows that are different between
in these tables the dealers.account_no is the same data as the
blackgate_users.User_Name dealers.DealerName is the same data as the
blackgate_users.DealerName I just want the rows that are in the dealers
table but not in the blackgate_users table. 


You want to do a join on the two tables, and make it conditional upon a
known failing value (e.g. if when they DO match up, blackgate_users
shouldn't be NULL - make that your condition).  That will return just
the rows in the first table that don't have a match.

- Martin Norland, Database / Web Developer, International Outreach x3257
The opinion(s) contained within this email do not necessarily represent
those of St. Jude Children's Research Hospital.

PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to