Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL Query Question
Message
From
17/11/2004 13:12:45
 
 
To
17/11/2004 09:47:57
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00961929
Message ID:
00962304
Views:
7
>VFP won't necessarily create a temp index. That will only happen if Rushmore thinks one will speed things up. I've seen times when the engine was wrong in selecting the order for joins (although extremely rare). That's exactly why the FORCE clause was added to the SQL SELECT command. From VFP Help (emphasis mine):
>
>"FORCE specifies that tables are joined in the order in which they appear in the FROM clause. If FORCE is omitted, Visual FoxPro attempts to optimize the query. However, the query might be executed faster by including the FORCE keyword to disable the Visual FoxPro query optimization."
>

It is true that, occasionally, we know better than the optimizer. But I still don't see why you said that a query involving more than two tables could only be partially optimized.

On the question of temp indexes, I'm not sure. I don't think a query ever joins tables using anything other than an index. Certainly, I've never seen that result from SYS(3054), with the exception of a cartesian join.

Tamar
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform