Re: Show differences between two tables

2006-09-15 Thread Dan Buettner

Hi Neil -

Something like this ought to work, joining on the ID column to find matches
between tables, then finding the enabled fields which are not equal.

SELECT a.fieldID, a.enabled, b.enabled
FROM TableA a, TableB b
WHERE a.fieldID = b.fieldID
AND a.enabled != b.enabled

Dan


On 9/15/06, Neil Tompkins [EMAIL PROTECTED] wrote:


Hi
I've two tables

TableA
FieldID
Enabled

TableB
FieldID
Enabled

What query would I need to show what FieldIDs which are the same, but the
enabled field status is different ?Thanks,
Neil
_
Be one of the first to try Windows Live Mail.

http://ideas.live.com/programpage.aspx?versionId=5d21c51a-b161-4314-9b0e-4911fb2b2e6d



RE: Show differences between two tables

2006-09-15 Thread Jerry Schwartz
This may be the blind leading the one-eyed, but wouldn't

SELECT FieldID FROM TableA, TableB WHERE TableA.FieldID = TableB.FieldID AND
TableA.Enabled != TableB.Enabled;

Work?


Regards,

Jerry Schwartz
Global Information Incorporated
195 Farmington Ave.
Farmington, CT 06032

860.674.8796 / FAX: 860.674.8341

-Original Message-
From: Neil Tompkins [mailto:[EMAIL PROTECTED]
Sent: Friday, September 15, 2006 5:04 AM
To: mysql@lists.mysql.com
Subject: Show differences between two tables

Hi
I've two tables

TableA
FieldID
Enabled

TableB
FieldID
Enabled

What query would I need to show what FieldIDs which are the same, but the
enabled field status is different ?Thanks,
Neil
_
Be one of the first to try Windows Live Mail.
http://ideas.live.com/programpage.aspx?versionId=5d21c51a-b161-4314-9b0e-491
1fb2b2e6d




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]