[MDEV-2778] LP:694092 - Wrong result with join_cache_level + index_condition_pushdown Created: 2010-12-24 Updated: 2015-02-02 Resolved: 2012-10-04 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Critical |
| Reporter: | Philip Stoev (Inactive) | Assignee: | Igor Babaev |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | Launchpad | ||
| Attachments: |
|
| Description |
|
If the following query is executed with join_cache_level=1 and index_condition_pushdown=on (the default values for both options), it returns 1 row whereas all other plans for this query, including full scans, return zero rows. Query: SELECT f2 FROM t2 explain: test case: CREATE TABLE t2 (f3 int(11), f2 varchar(1024), f4 varchar(10), PRIMARY KEY (f3)) ; SELECT f2 FROM t2 JOIN t1 FORCE KEY (PRIMARY) ON t1.f1 = t2.f4 WHERE t2.f3 AND t2.f3 <= 4 AND t1.f3 IN ( 2 , 1 ) OR t1.f3 > 1 AND t1.f3 < 5 AND t2.f3 BETWEEN 6 AND 6 ; maria-5.3 , maria-5.3-wl128 and maria-5.3-wl128-dsmrr-cpk are all affected. The FORCE KEY is only required to produce a stable execution plan, the problem was also observed without FORCE KEY. |
| Comments |
| Comment by Philip Stoev (Inactive) [ 2010-12-24 ] |
|
Re: Wrong result with join_cache_level + index_condition_pushdown |
| Comment by Rasmus Johansson (Inactive) [ 2011-12-13 ] |
|
Launchpad bug id: 694092 |