Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can't optimize view
Message
De
16/09/1998 18:55:55
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
À
15/09/1998 16:59:00
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00137005
Message ID:
00137563
Vues:
15
>I have a view created with synatax like the following:
>CREATE SQL VIEW myView AS;
>SELECT table.field1, table1.field2, table2.field1,;
> table1.field1-table1.field2 as calc;
>FROM table1,table2;
>WHERE table1.fk = table.pk;
>AND table1.field1 > table1.field2
>
>I have indexes on the fields used in the join, and an index on table1.field1 > table1.field2.
>This view runs extremely slowly, and SQL Showplan shows that there is no optimization on either table.
>
>What else can I do to speed this up?

Maybe...
AND (table1.field1 > table1.field2 )=.t.

...since you have an index on that expression, it should constitute a side of a relation expression, as the book says. I know this sounds silly, like most of the other things I'm writing today (west wind? sun spots? I'm under influence of myself? Who knows.), but shouldn't take long to try.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform