diff options
Diffstat (limited to '')
-rw-r--r-- | mysql-test/main/derived_opt.result | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/mysql-test/main/derived_opt.result b/mysql-test/main/derived_opt.result index cf0c1cb6..2f3b29c5 100644 --- a/mysql-test/main/derived_opt.result +++ b/mysql-test/main/derived_opt.result @@ -92,13 +92,13 @@ pla_id test explain SELECT STRAIGHT_JOIN d.pla_id, m2.mat_id FROM t1 m2 INNER JOIN (SELECT mp.pla_id, MIN(m1.matintnum) AS matintnum FROM t2 mp INNER JOIN t1 m1 ON mp.mat_id=m1.mat_id GROUP BY mp.pla_id) d ON d.matintnum=m2.matintnum; id select_type table type possible_keys key key_len ref rows Extra 1 PRIMARY m2 ALL NULL NULL NULL NULL 9 -1 PRIMARY <derived2> ref key0 key0 7 test.m2.matintnum 2 +1 PRIMARY <derived2> ref key0 key0 7 test.m2.matintnum 1 2 DERIVED mp ALL NULL NULL NULL NULL 9 Using temporary; Using filesort 2 DERIVED m1 eq_ref PRIMARY PRIMARY 3 test.mp.mat_id 1 explain SELECT STRAIGHT_JOIN d.pla_id, m2.test FROM t1 m2 INNER JOIN (SELECT mp.pla_id, MIN(m1.matintnum) AS matintnum FROM t2 mp INNER JOIN t1 m1 ON mp.mat_id=m1.mat_id GROUP BY mp.pla_id) d ON d.matintnum=m2.matintnum; id select_type table type possible_keys key key_len ref rows Extra 1 PRIMARY m2 ALL NULL NULL NULL NULL 9 -1 PRIMARY <derived2> ref key0 key0 7 test.m2.matintnum 2 +1 PRIMARY <derived2> ref key0 key0 7 test.m2.matintnum 1 2 DERIVED mp ALL NULL NULL NULL NULL 9 Using temporary; Using filesort 2 DERIVED m1 eq_ref PRIMARY PRIMARY 3 test.mp.mat_id 1 drop table t1,t2; @@ -323,10 +323,9 @@ JOIN t1 AS tc ON (tb.pk = tc.pk) JOIN t4 AS td ON tc.a = td.a) tu) limit 10; id select_type table type possible_keys key key_len ref rows Extra -1 PRIMARY <subquery2> ALL distinct_key NULL NULL NULL # +1 PRIMARY <derived3> ALL distinct_key NULL NULL NULL # 1 PRIMARY tx eq_ref PRIMARY PRIMARY 4 tu.pk # Using index 1 PRIMARY ty eq_ref PRIMARY PRIMARY 4 tu.pk # Using index -2 MATERIALIZED <derived3> ALL NULL NULL NULL NULL # 3 DERIVED td system PRIMARY NULL NULL NULL # Using temporary 3 DERIVED tc ref PRIMARY,a a 3 const # 3 DERIVED ta eq_ref PRIMARY PRIMARY 4 test.tc.pk # Using index @@ -535,7 +534,7 @@ ON t2.id=t.id WHERE t2.id < 3; id select_type table type possible_keys key key_len ref rows Extra 1 PRIMARY t2 range PRIMARY PRIMARY 4 NULL 2 Using index condition -1 PRIMARY <derived2> ref key0 key0 5 test.t2.id 2 +1 PRIMARY <derived2> ref key0 key0 5 test.t2.id 1 2 DERIVED t1 ALL NULL NULL NULL NULL 8 Using temporary; Using filesort set join_cache_level=default; set optimizer_switch= @save_optimizer_switch; |