Subject | Re: "IN" and several "=" and "and" |
---|---|
Author | james_027 |
Post date | 2005-05-25T06:43:58Z |
> The first one will be faster because it will return nothing :-)Hi Ivan,
>
> But if you want to compare these two
> where id = 1 or id = 2 or id = 4 or id = 6 or id = 8 or id = 10
> where id in (1, 2, 4, 6, 8, 10)
> that they are internally processed identically.
>
> Ivan
> http://www.volny.cz/iprenosil/interbase/
Sorry I've made a mistake. I do mean the "where id = 1 or id = 2 or id
= 4 or id = 6 or id = 8 or id = 10". Thanks for making the point clear
to me. My next question is that does this kind of query optimezed the
uses of Index? What about its performance in non index columns?
Cheers,
James