Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 6 of 6 total
Thread IN vs OR
Sun, Jul 21 2013 9:27 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Tim

Much time ago in the dim and distant land of DBISAM multiple ORs were better than IN. I seem to recall that changed.

Which is the better in ElevateDB, or are they pretty much the same? eg if one form meant less work for the sql preparation I'll generate code for that form.

Roy Lambert
Sun, Jul 21 2013 9:32 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

ps


I've currently got things set up to generate INs

Roy Lambert
Sun, Jul 21 2013 1:29 PMPermanent Link

Malcolm Taylor

Hi Roy

I have no measurements available, but a long time ago I used to work
with Informix and IN was known to be very slow.  I found the same in
DBIsam.
As a result I have always tried to avoid IN unless with a small set of
values and 'modest' row numbers.
I don't know how IN is implemented so I can't explain.
I imagine Tim will pop up some day to enlighten us.
Maybe someone can find it in the source...

Malcolm
Sun, Jul 21 2013 2:31 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< Much time ago in the dim and distant land of DBISAM multiple ORs were
better than IN. I seem to recall that changed. >>

You'd have to point me to where it was said that using ORs were faster than
IN. Smile

<< Which is the better in ElevateDB, or are they pretty much the same? eg if
one form meant less work for the sql preparation I'll generate code for that
form. >>

IN will be ever-so-slightly faster due to the fact that it has a more
efficient expression structure, but that's about it.

Tim Young
Elevate Software
www.elevatesoft.com
Mon, Jul 22 2013 3:21 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Tim

>You'd have to point me to where it was said that using ORs were faster than
>IN. Smile

If I can ever think up how to query my newsgroup archive to find it I will. Just entering OR and IN as search terms is not liable to be productive Frown

>IN will be ever-so-slightly faster due to the fact that it has a more
>efficient expression structure, but that's about it.

Thanks - especially since its easier to build an IN

Roy
Mon, Jul 22 2013 3:40 AMPermanent Link

Malcolm Taylor

Tim Young [Elevate Software] wrote:

> IN will be ever-so-slightly faster due to the fact that it has a more
> efficient expression structure, but that's about it.
>
That's good to know.  I have erased my bias against IN. Surprised
Image