Subject | Re: [ib-support] A Gotcha with SELECT FIRST |
---|---|
Author | Martijn Tonies |
Post date | 2002-05-01T15:17:26Z |
> from Release Notes v.1.0.1:PK1 is probably a field in Primary Key 1 :)
>
> "
> A Gotcha with SELECT FIRST
> This
>
> delete from TAB1 where PK1 in (select first 10 PK1 from TAB1);
>
> will delete all of the rows in the table. Ouch! the sub-select is
> evaluating each 10 candidate rows for deletion, deleting them, slipping
> forward 10 more...ad infinitum, until there are no rows left. Beware!
> "
>
> Question: what is PK1 ?
Just an example...
Martijn Tonies
InterBase Workbench - the developer tool for InterBase and Firebird
http://www.interbaseworkbench.com
Upscene Productions
http://www.upscene.com
"This is an object-oriented system.
If we change anything, the users object."