Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to optimize this simple 'inner join'?
Message
From
29/09/2000 00:07:20
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
How to optimize this simple 'inner join'?
Miscellaneous
Thread ID:
00422415
Message ID:
00422415
Views:
43
Hi everyone.

I have two tables this way:

Master : Primary key = Field1 + Field2

Detail : Regular index = Field1 + Field2 (Just like Master-Primary key)

I am trying to see how VFP get optimized queries and found this:

Select * from detail where field1+field2 = master.field1 + master.field2.

It is optimized (sys(3054,1)) and works very fast, but of course, it only takes one record from master table.

Now, I want all records using 'inner join' and similar expressions:

Select * from master inner join detail on ;
master.field1 + master.field2 = detail.field1 + detail.field2

Optimization: None.
Why this statement is not optimized?

Thanks.

Juan Carlos
Next
Reply
Map
View

Click here to load this message in the networking platform