summaryrefslogtreecommitdiff
path: root/mysql-test/r/maria_mrr.result
diff options
context:
space:
mode:
authorSergey Petrunya <psergey@askmonty.org>2010-11-09 18:02:08 +0200
committerSergey Petrunya <psergey@askmonty.org>2010-11-09 18:02:08 +0200
commit3d698ac61618f658e5a25219d3eb3b29b451db00 (patch)
treeaffc497d6401ffe9001e7596d821e098ea1e3b44 /mysql-test/r/maria_mrr.result
parent594a8648ef133705638ef909667157cb47ae0aee (diff)
downloadmariadb-git-3d698ac61618f658e5a25219d3eb3b29b451db00.tar.gz
BUG#671361: virtual int Mrr_ordered_index_reader::refill_buffer(): Assertion `!know_key_tuple_params
- Make sure we have enough space for both rowids and keys.
Diffstat (limited to 'mysql-test/r/maria_mrr.result')
-rw-r--r--mysql-test/r/maria_mrr.result37
1 files changed, 37 insertions, 0 deletions
diff --git a/mysql-test/r/maria_mrr.result b/mysql-test/r/maria_mrr.result
index 3b43f4f17d2..9153d795a17 100644
--- a/mysql-test/r/maria_mrr.result
+++ b/mysql-test/r/maria_mrr.result
@@ -365,3 +365,40 @@ id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t2 ALL PRIMARY,idx NULL NULL NULL 16 Using where; Using join buffer (flat, BNL join)
1 SIMPLE t3 ref PRIMARY,idx idx 3 test.t2.v 2 Using index condition; Using where
DROP TABLE t1,t2,t3;
+#
+# BUG#671361: virtual int Mrr_ordered_index_reader::refill_buffer(): Assertion `!know_key_tuple_params
+# (works only on Maria because we need 1024-byte long key)
+#
+SET SESSION optimizer_use_mrr = 'force';
+SET SESSION join_cache_level = 6;
+SET SESSION join_buffer_size = 1024;
+CREATE TABLE t1 (
+pk int(11) NOT NULL AUTO_INCREMENT,
+col_varchar_1024_latin1_key varchar(1024) DEFAULT NULL,
+PRIMARY KEY (pk),
+KEY col_varchar_1024_latin1_key (col_varchar_1024_latin1_key)
+) ENGINE=Aria;
+INSERT INTO t1 VALUES
+(1,'z'),
+(2,'abcdefjhjkl'),
+(3,'in'),
+(4,'abcdefjhjkl'),
+(6,'abcdefjhjkl');
+CREATE TABLE t2 (
+col_varchar_10_latin1 varchar(10) DEFAULT NULL
+) ENGINE=Aria;
+INSERT INTO t2 VALUES ('foo'), ('foo');
+EXPLAIN SELECT count(*)
+FROM t1 AS table1, t2 AS table2
+WHERE
+table1.col_varchar_1024_latin1_key = table2.col_varchar_10_latin1 AND table1.pk<>0 ;
+id select_type table type possible_keys key key_len ref rows Extra
+1 SIMPLE table2 ALL NULL NULL NULL NULL 2 Using where
+1 SIMPLE table1 ref PRIMARY,col_varchar_1024_latin1_key col_varchar_1024_latin1_key 1027 test.table2.col_varchar_10_latin1 2 Using index condition(BKA); Using where; Using join buffer (flat, BKA join)
+SELECT count(*)
+FROM t1 AS table1, t2 AS table2
+WHERE
+table1.col_varchar_1024_latin1_key = table2.col_varchar_10_latin1 AND table1.pk<>0 ;
+count(*)
+0
+drop table t1, t2;