Subject Re: [ib-support] Is a joined query faster than a subquery, or doesn't it matter?
Author Jörg Schiemann
Thanks Guido,

I didn't expect this but it is good to know.

Regards

und alles Gute

Jörg

----- Original Message -----
From: <guido.klapperich@...>
To: <ib-support@yahoogroups.com>
Sent: Wednesday, February 14, 2001 2:04 PM
Subject: Re: [ib-support] Is a joined query faster than a subquery, or
doesn't it matter?


> Hi Jörg
>
> I have asked the same question half a year ago in the IBO-Mailinglist.
These
> are the results in short words:
> 1) When you just do a select without an order by, it doesn't matter, if
you
> use a Join or a SubSelect.
> 2) When you select with an order by, you should use the subselect.
>
>
> Guido.
>
> Jörg Schiemann wrote:
>
> > Hi,
> >
> > I've a master and a detail table like
> >
> > create table "SampleMaster" (
> > MasterID integer not null primary key,
> > OrderNo integer not null,
> > Comment varchar(20),
> > .
> > .
> > .
> > );
> >
> > and
> >
> > create table "SampleDetail" (
> > DetailID integer not null primary key,
> > MasterID integer not null,
> > OrderPos integer not null,
> > quantity integer not null,
> > .
> > .
> > .
> > constraint fk_MasterID foreign key (MasterID) references SampleMaster
> > (MasterID)
> > );
> >
> > Is a query with a subquery faster then a joined query if I want all
fields
> > from the SampleDetail and only OrderNo from SampleMaster?
> >
> > TIA
> >
> > Jörg Schiemann
> >
> >
> > To unsubscribe from this group, send an email to:
> > ib-support-unsubscribe@egroups.com
>
>
>
> To unsubscribe from this group, send an email to:
> ib-support-unsubscribe@egroups.com
>
>
>
>