Subject Re: [firebird-support] it´s a bug?
Author Hans
Probably all due to the fact that F2.0 doesn't use an index
while performing the NOT IN (SELECT .... ) and it may
take forever with large tables, unlike FB1.5

After changing the NOT IN (SELECT to NOT EXISTS (SELECT .... WHERE ..)
and it all worked fine again.:

>I´m using FB2.0 I´ve a select like this:
>select *
>from cabpedido
>where
>codigo not in (select Codpedido from linalbar)

>this select dosen´t return any value because se second select retrn´s null
>values

>if I change the select by this
>select *
>from cabpedido
>where
>codigo not in (select Codpedido from linalbar where CodPedido is not null)

>work´s fine. In FB 1.5 the first format work´s fine

>thanks