Subject Re: [Firebird-Architect] Re: the insert into t select * from t infinite
Author Jim Starkey
Dmitry Yemanov wrote:

>"Alexandre Benson Smith" <iblist@...> wrote:
>
>
>>One thing that most newcomers to FB strikes is
>>
>>select
>> *
>>from
>> A
>>where
>> AI.B_ID in (select B.B_ID from B where B.B = 'X')
>>
>>This query are treated as correlated, but in fact aren't there is some
>>possibility to solve the both problems (infinite loop and this) at once ?
>>
>>
>
>
>
The smart way to handle this is to factor out the inner select, using
the inner select to compute an index bitmap for A.B_ID, then use the
bitmap to drive the outer select.

--

Jim Starkey
Netfrastructure, Inc.
978 526-1376