Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Select - the inner execution sequence
Message
 
 
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Autre
Divers
Thread ID:
00825026
Message ID:
00825175
Vues:
20
Sergey,
>Each database engine has it's own query optimizer which >desides how to execute particular query by building an >execution plan.
But i have to be certain that one and the same SELECT produces the same result through changing server versions.
In this particular case i have to be sure that Dep is joined to what is left of Place1 after it was joined to Pc1 (see item 3) below). So i guess there should be some basic rules for building result of a SELECT. In other words the sceleton is there but meat is the buisness of the query optimizer.

>VFP doesn't provide access to the execution plan. You can >only guess and find the best one with trail and error.
About a year ago i read Jim Booth's article (sadly i've lost it) where he explaned VFP SELECT result building. For example he explaned the difference between
JOIN T1 ON ...
JOIN T2 ON ...
and
JOIN T1
JOIN T2
ON...
ON...

Best wishes
Kamil



>Hi Kamil,
>
>Each database engine has it's own query optimizer which desides how to execute particular query by building an execution plan. SQL Server allow you to view the execution plan it produces when you run query in the Query Analizer. After query has been executed, press CTRL+L or corresponded tollbar button/menu item to view it. You can find more about that in BOL.
>VFP doesn't provide access to the execution plan. You can only guess and find the best one with trail and error.
>
>>Hi.
>>I'd like to know the inner execution sequence when building the result of the following satement.
>>
select Pc1.*, Place1.User_Na, Place1.Dep_Pk,
>>Dep.Na as Dep_Na from Pc1
>>join Place1 on Pc1.Place1_Pk=Place1.pk
>>join Dep on Dep.Pk=Place1.Dep_pk
>>where Pc1.Place1_PK in
>>(Select PK from Place1 where PK in
>>(Select Place1_pk from Place1_Po1))
>>order by User_na
>>Here is how i see it.
>>1) WHERE is executed and Pc1 is filtered accordingly.
>>2) Place1 is joined to what is left of Pc1.
>>3) How Dep is joined to Place1 i don't know. Either Place1 is taken as a seperate table and Dep is joined to it or Dep is joined to what is left of Place1 after it was joined to Pc1 (something i'm aming to achieve).
>>4) The result is ordered.
>>
>>And for that matter, can you direct me to the internet resource which would give a general explenation to the subject (preferably VFP SELECT inner sequence too).
>>
>>Thank you in advance.
>>Kamil.
A moment of silence is our cosmic reset button.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform