Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sql not always rushmore'd
Message
De
15/04/2006 16:20:46
Mike Yearwood
Toronto, Ontario, Canada
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01113886
Message ID:
01113893
Vues:
34
>Hi Michael.
>
>Why should the field always be on the LHS.? Both queries produce exactly the same results.

It's just easier to create a parser that follows a simple rule like optimize by looking at the expression on the LHS.

It's right in the VFP help
A basic optimizable expression takes one of the two following forms:
              eIndex relOp eExp
-or-
              eExpr relOp eIndex
            
A basic optimizable expression has the following characteristics: 

eIndex exactly matches the expression on which an index is constructed.

eExpr is any expression and can include variables and fields from other unrelated tables.

relOp is one of the following relational operators: <, >, =, <=, >=, <>, #, ==, or !=. You can also use the ISNULL( ), BETWEEN( ), or INLIST( ) functions (or their SQL equivalents such as IS NULL, and so on).
In form one eIndex is optimized, not eExp. In form 2 eExpr is optimized, not eIndex. Been that way a long time.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform