MySQL Question

smack Down

Diamond Member
Sep 10, 2005
4,507
0
0
I have two table both of witch have 2 columns in common. I want to be able to get a list of the element in the table where the data in the first column match but the data in the second does not. Is there anyway to do something like or do I have to just read all the data and do the compare manual.
 

clamum

Lifer
Feb 13, 2003
26,256
406
126
Something like this?

SELECT <what fields you want>
FROM table1, table2
WHERE table1.column1 = table2.column2
AND table1.column2 <> table2.column2