Need to find out which rows from select 1 are not present in select 2,
but is it possible to make som kind of union that only returns the
overlapping rows from the two selects?
Sincerely
Victor
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:
for example:
Table1 contains: A and B and C
Table2 contains: B and C and D
all varchars
The query:
select A, B, C, '' as D from Table1
UNION
select '' as A, B, C, D from Table2
if the values are no varchar but for example smallints then you replace the
'' with 0 or whatever wich value (eg NULL).
Of course,
But you still can see the table structure???
Hans
At 16:05 15-10-03 +0200, you wrote:
2003-10-15 kl. 15.51 skrev Hans van Dalen:
Table1 contains: A and B and C
Table2 contains: B and C and D
all varchars
The query:
select A, B, C, '' as D from Table1
UNION
select '' as A,