Details
-
Task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
None
Description
Say, the query is
SELECT ... FROM t1, t2 WHERE t1_a=t2_b AND t1_c=10 AND t1_d=20 |
When optimizer considers ref access for t1 using the index on t1_c, it uses records_in_range to estimate the number of rows that will be selected. But there is a second condition (on t1_d) and it will further limit the number of rows. Basically, the optimizer should understand that independently from the access method on t1 only those rows will be selected that match both conditions, and use this estimate, again, independently from the access method.