Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to optimize this simple 'inner join'?
Message
De
29/09/2000 00:07:20
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
How to optimize this simple 'inner join'?
Divers
Thread ID:
00422415
Message ID:
00422415
Vues:
42
Hi everyone.

I have two tables this way:

Master : Primary key = Field1 + Field2

Detail : Regular index = Field1 + Field2 (Just like Master-Primary key)

I am trying to see how VFP get optimized queries and found this:

Select * from detail where field1+field2 = master.field1 + master.field2.

It is optimized (sys(3054,1)) and works very fast, but of course, it only takes one record from master table.

Now, I want all records using 'inner join' and similar expressions:

Select * from master inner join detail on ;
master.field1 + master.field2 = detail.field1 + detail.field2

Optimization: None.
Why this statement is not optimized?

Thanks.

Juan Carlos
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform