summaryrefslogtreecommitdiff
path: root/mysql-test/r/subselect2.result
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/r/subselect2.result')
-rw-r--r--mysql-test/r/subselect2.result24
1 files changed, 12 insertions, 12 deletions
diff --git a/mysql-test/r/subselect2.result b/mysql-test/r/subselect2.result
index 31e7774734e..f151ce00a5a 100644
--- a/mysql-test/r/subselect2.result
+++ b/mysql-test/r/subselect2.result
@@ -126,13 +126,13 @@ c373e9f5ad07993f3859444553544200 Last Discussion c373e9f5ad079174ff1744455354420
EXPLAIN SELECT t2.*, t4.DOCTYPENAME, t1.CONTENTSIZE,t1.MIMETYPE FROM t2 INNER JOIN t4 ON t2.DOCTYPEID = t4.DOCTYPEID LEFT OUTER JOIN t1 ON t2.DOCID = t1.DOCID WHERE t2.FOLDERID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID='2f6161e879db43c1a5b82c21ddc49089' AND t3.FOLDERNAME = 'Level1') AND t3.FOLDERNAME = 'Level2') AND t3.FOLDERNAME = 'Level3') AND t3.FOLDERNAME = 'CopiedFolder') AND t3.FOLDERNAME = 'Movie Reviews') AND t2.DOCNAME = 'Last Discussion';
id select_type table type possible_keys key key_len ref rows Extra
1 PRIMARY t2 ALL DDOCTYPEID_IDX,DFOLDERID_IDX NULL NULL NULL 9 Using where
-1 PRIMARY t1 eq_ref PRIMARY PRIMARY 34 test.t2.DOCID 1
-1 PRIMARY t4 eq_ref PRIMARY PRIMARY 34 test.t2.DOCTYPEID 1
-1 PRIMARY t3 eq_ref PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX PRIMARY 34 test.t2.FOLDERID 1 Using where
-1 PRIMARY t3 eq_ref PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX PRIMARY 34 test.t3.PARENTID 1 Using where
-1 PRIMARY t3 eq_ref PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX PRIMARY 34 test.t3.PARENTID 1 Using where
-1 PRIMARY t3 eq_ref PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX PRIMARY 34 test.t3.PARENTID 1 Using where
-1 PRIMARY t3 eq_ref PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX PRIMARY 34 test.t3.PARENTID 1 Using where
+1 PRIMARY t1 hash_ALL PRIMARY #hash#PRIMARY 34 test.t2.DOCID 2 Using join buffer (flat, BNLH join)
+1 PRIMARY t4 hash_ALL PRIMARY #hash#PRIMARY 34 test.t2.DOCTYPEID 10 Using join buffer (incremental, BNLH join)
+1 PRIMARY t3 hash_ALL PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX #hash#PRIMARY 34 test.t2.FOLDERID 21 Using where; Using join buffer (incremental, BNLH join)
+1 PRIMARY t3 hash_ALL PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX #hash#PRIMARY 34 test.t3.PARENTID 21 Using where; Using join buffer (incremental, BNLH join)
+1 PRIMARY t3 hash_ALL PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX #hash#PRIMARY 34 test.t3.PARENTID 21 Using where; Using join buffer (incremental, BNLH join)
+1 PRIMARY t3 hash_ALL PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX #hash#PRIMARY 34 test.t3.PARENTID 21 Using where; Using join buffer (incremental, BNLH join)
+1 PRIMARY t3 hash_ALL PRIMARY,FFOLDERID_IDX,CMFLDRPARNT_IDX #hash#PRIMARY 34 test.t3.PARENTID 21 Using where; Using join buffer (incremental, BNLH join)
drop table t1, t2, t3, t4;
CREATE TABLE t1 (a int(10) , PRIMARY KEY (a)) Engine=InnoDB;
INSERT INTO t1 VALUES (1),(2);
@@ -162,7 +162,7 @@ EXPLAIN
SELECT * FROM t2,t3 WHERE (2,9) IN (SELECT DISTINCT a,pk FROM t1) OR a = b;
id select_type table type possible_keys key key_len ref rows Extra
1 PRIMARY t2 index a a 5 NULL 2 Using where; Using index
-1 PRIMARY t3 ref b b 5 test.t2.a 2 Using index
+1 PRIMARY t3 hash_index b #hash#b:b 5:5 test.t2.a 4 Using index; Using join buffer (flat, BNLH join)
2 SUBQUERY t1 const PRIMARY,a PRIMARY 4 const 1 Using where
SELECT * FROM t2,t3 WHERE (2,9) IN (SELECT DISTINCT a,pk FROM t1) OR a = b;
pk a b
@@ -171,7 +171,7 @@ EXPLAIN
SELECT * FROM t2,t3 WHERE (2,9) IN (SELECT DISTINCT a,pk FROM v1) OR a = b;
id select_type table type possible_keys key key_len ref rows Extra
1 PRIMARY t2 index a a 5 NULL 2 Using where; Using index
-1 PRIMARY t3 ref b b 5 test.t2.a 2 Using index
+1 PRIMARY t3 hash_index b #hash#b:b 5:5 test.t2.a 4 Using index; Using join buffer (flat, BNLH join)
2 SUBQUERY t1 const PRIMARY,a PRIMARY 4 const 1 Using where
SELECT * FROM t2,t3 WHERE (2,9) IN (SELECT DISTINCT a,pk FROM v1) OR a = b;
pk a b
@@ -258,8 +258,8 @@ WHERE t2c.c2 = t2b.c2 AND ( t2a.m = t2b.n OR 0 ) AND
id select_type table type possible_keys key key_len ref rows filtered Extra
1 PRIMARY t1 ALL NULL NULL NULL NULL 2 100.00 Using where
2 DEPENDENT SUBQUERY t2a ALL NULL NULL NULL NULL 2 100.00 Using where
-2 DEPENDENT SUBQUERY t2b ALL NULL NULL NULL NULL 2 100.00 Using where; Using join buffer (flat, BNL join)
-2 DEPENDENT SUBQUERY t2c ALL NULL NULL NULL NULL 2 100.00 Using where; Using join buffer (incremental, BNL join)
+2 DEPENDENT SUBQUERY t2b hash_ALL NULL #hash#$hj 5 test.t2a.m 2 100.00 Using where; Using join buffer (flat, BNLH join)
+2 DEPENDENT SUBQUERY t2c hash_ALL NULL #hash#$hj 4 test.t2b.c2 2 100.00 Using where; Using join buffer (incremental, BNLH join)
Warnings:
Note 1276 Field or reference 'test.t1.a' of SELECT #2 was resolved in SELECT #1
Note 1003 /* select#1 */ select `test`.`t1`.`a` AS `a`,`test`.`t1`.`c1` AS `c1` from `test`.`t1` where !<expr_cache><`test`.`t1`.`c1`,`test`.`t1`.`a`>(<in_optimizer>(`test`.`t1`.`c1`,<exists>(/* select#2 */ select `test`.`t2a`.`c2` from `test`.`t2` `t2a` join `test`.`t2` `t2b` join `test`.`t2` `t2c` where (`test`.`t2b`.`m` <> `test`.`t1`.`a` or `test`.`t2b`.`m` = `test`.`t2a`.`m`) and trigcond(<cache>(`test`.`t1`.`c1`) = `test`.`t2a`.`c2` or `test`.`t2a`.`c2` is null) and `test`.`t2c`.`c2` = `test`.`t2b`.`c2` and `test`.`t2b`.`n` = `test`.`t2a`.`m` having trigcond(`test`.`t2a`.`c2` is null))))
@@ -339,7 +339,7 @@ where t1.a = t2.a and ( t1.a = ( select min(a) from t1 ) or 0 );
id select_type table type possible_keys key key_len ref rows filtered Extra
1 PRIMARY t1 ALL NULL NULL NULL NULL 2 100.00 Using where
1 PRIMARY t2 ALL NULL NULL NULL NULL 3 100.00 Using where; Using join buffer (flat, BNL join)
-1 PRIMARY t3 ref idx idx 6 func 2 100.00 Using where; Using index
+1 PRIMARY t3 hash_index idx #hash#idx:idx 6:6 func 3 66.67 Using where; Using index; Using join buffer (incremental, BNLH join)
2 SUBQUERY t1 ALL NULL NULL NULL NULL 2 100.00
Warnings:
Note 1003 /* select#1 */ select `test`.`t1`.`a` AS `a`,`test`.`t2`.`a` AS `a`,`test`.`t3`.`a` AS `a` from `test`.`t1` join `test`.`t2` left join `test`.`t3` on(`test`.`t3`.`a` = `test`.`t1`.`a`) where `test`.`t1`.`a` = (/* select#2 */ select min(`test`.`t1`.`a`) from `test`.`t1`) and `test`.`t2`.`a` = (/* select#2 */ select min(`test`.`t1`.`a`) from `test`.`t1`)