Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Simple VFP query, no optimization
Message
De
10/11/2000 16:31:11
Jonathan Cochran
Alion Science and Technology
Maryland, États-Unis
 
 
À
10/11/2000 16:27:05
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00440476
Message ID:
00440482
Vues:
9
Do you have a filter on the index? Filtered indexes cannot be optimized. I can't think of anything else off the top of my head.

HTH,
Jonathan

>I've got the simplest of queries that I cannot get to optimize. Table pastinvoices has a regular index with expression custID+poNum. The following two queries (hard coded for example only) return the proper invoice, but takes about 3 seconds. Running a query on the primary key (invnum), returns the record in .03 seconds.
>
>Here they are:
>
>select * from pastinvoices as pinv where pinv.custID = "149" and ;
> pinv.poNum = "143619" into cursor cp
>
>-- or --
>
>select * from pastinvoices as pinv where (pinv.custID + pinv.ponum = ;
> "149 143619 ") into cursor cp && padded on right in act of desperation
>
>My where clause is identical to one of my index expressions. SET OPTIMIZE = ON. Where is my shortcoming?
>
>About to revert to INDEXSEEK and manually build cursor,
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform