SELECT Table1.ID FROM Table1 LEFT OUTER JOIN Table2 ON
Table1.ID=Table2.ID
WHERE Table2.ID IS NULL;
> -Original Message-
> From: Henning Sittler [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, December 03, 2002 10:16 AM
> To: 'mysql users'
> Subject: MySQL: Select N
Thanks to all those who have responded! This is the sql query I am looking
for. It's good to have such a user mail list.
SELECT Table1.ID FROM Table1 LEFT JOIN Table2 Using(ID)
WHERE Table2.ID IS NULL
when you do a left join, if there is no cooresponding row in the second
table, then a row
SELECT Table1.ID FROM Table1 LEFT JOIN Table2 ON Table1.ID = TRable2.ID
where Table2.ID IS NULL;
Henning Sittler wrote:
Just wondering if anyone knows of a work around for selecting rows in Table1
that have an ID column value which is not found in the ID column of Table2.
I have seen a workarou
p://iConnect.de>
Heesestr. 6, 12169 Berlin (Germany)
Tel: +49 30 7970948-0 Fax: +49 30 7970948-3
- Original Message -
From: "Henning Sittler" <[EMAIL PROTECTED]>
To: "'mysql users'" <[EMAIL PROTECTED]>
Sent: Tuesday, December 03, 2002 3:16
Just wondering if anyone knows of a work around for selecting rows in Table1
that have an ID column value which is not found in the ID column of Table2.
I have seen a workaround for selecting similar rows IN both tables, but I
want NOT IN.
This would be a work around to the sql subselect query in