Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Index on multiple integer fields
Message
De
20/12/2005 10:35:06
 
 
À
20/12/2005 09:59:00
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows 2000 SP4
Database:
Visual FoxPro
Divers
Thread ID:
01079271
Message ID:
01079548
Vues:
24
>>>"Correct" gets the job done. "Efficient" is a different issue.
>>>
>>>Here's an example:
>>>You have a table (Customers) with 1 million rows. There is an index (FullName) on UPPER(LastName + FirstName). What is the "correct" way of finding a particular name? Is it:
>>>
>>>a) LOCATE UPPER(m.LastName + m.FirstName)?
>>>b) SET ORDER TO TAG FullName then SEEK UPPER(m.LastName + m.FirstName)?
>>>c) SEEK(UPPER(m.LastName + m.FirstName), "Customers", "FullName")?
>>>d) SELECT * FROM Customers WHERE UPPER(LastName + FirstName) = UPPER(m.LastName + m.FirstName)?
>>>
>>>Answer is:
>>>All of the above are "correct", but some are more efficient than others.
>>>
>>
>>Then, among the 4 solutions, what is the "correct" choice ?
>>
>
>All are "correct" as they will all get the needed results.

terrible.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform