Subject | Re: [firebird-support] Generic SQL question |
---|---|
Author | Kjell Rilbe |
Post date | 2005-05-17T05:39:28Z |
Perhaps I should add that what I want is to get all F records whose ID
does not appear in table T (column T.ID).
Kjell
Kjell Rilbe wrote:
--------------------------------------
Kjell Rilbe
Adressmarknaden AM AB
E-post: kjell.rilbe@...
Telefon: 08-761 06 55
Mobil: 0733-44 24 64
does not appear in table T (column T.ID).
Kjell
Kjell Rilbe wrote:
> Just have to make sure I'm not going crazy. Please confirm that these--
> two SQL statements should return the same result:
>
> select count(*)
> from F
> where not exists (
> select 1
> from T
> where T.ID = F.ID
> )
>
> select count(*)
> from F
> where ID not in (
> select ID
> from T
> )
--------------------------------------
Kjell Rilbe
Adressmarknaden AM AB
E-post: kjell.rilbe@...
Telefon: 08-761 06 55
Mobil: 0733-44 24 64