[MDEV-622] LP:1002508 - The number of expected rows to be examined is off for a query with ORDER BY Created: 2012-05-21 Updated: 2012-11-22 Resolved: 2012-11-22 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 5.5.28a |
| Type: | Bug | Priority: | Minor |
| Reporter: | Igor Babaev | Assignee: | Igor Babaev |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | Launchpad | ||
| Attachments: |
|
| Description |
|
If to create and populate tables t1,t2 with the commands CREATE TABLE t1(a int PRIMARY KEY, b int) ENGINE=myisam; then Mariadb 5.5 will return the following explain output for the query MariaDB [test]> EXPLAIN
-----
----- The expected number of the examined rows from t1 is 4 though it should be 8 as for the following query: MariaDB [test]> EXPLAIN SELECT t1.a FROM t1 LEFT JOIN t2 ON t1.a=t2.a ORDER BY t1.a LIMIT 1000;
-----
----- |
| Comments |
| Comment by Rasmus Johansson (Inactive) [ 2012-05-21 ] |
|
Launchpad bug id: 1002508 |
| Comment by Igor Babaev [ 2012-05-21 ] |
|
Re: The number of expected rows to be examined is off for a query with ORDER BY |
| Comment by Igor Babaev [ 2012-11-20 ] |
|
The bug is reproducible with mariadb-5.2/5.3 as well. |
| Comment by Igor Babaev [ 2012-11-22 ] |
|
The fix was pushed into mariadb-5.5 (rev 3575). |