mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
Optimisation if simple IN subselect with primary index
(SCRUM) (part of WL#818) mysql-test/r/subselect.result: test of new optimisation mysql-test/t/subselect.test: test of new optimisation sql/item_subselect.cc: new engine for simple IN with primary index sql/item_subselect.h: new engine for simple IN with primary index sql/sql_lex.h: fixed typo sql/sql_select.cc: engine changing report_error can't be static, because it used in new engine sql/sql_select.h: new JT_ type (just for information in EXPLAIN statement) report_error can't be static, because it used in new engine
This commit is contained in:
@@ -819,6 +819,8 @@ insert into t2 values (2), (3), (4), (5);
|
||||
insert into t3 values (10,3), (20,4), (30,5);
|
||||
select * from t2 where t2.a in (select a from t1);
|
||||
explain select * from t2 where t2.a in (select a from t1);
|
||||
select * from t2 where t2.a in (select a from t1 where t1.b <> 30);
|
||||
explain select * from t2 where t2.a in (select a from t1 where t1.b <> 30);
|
||||
select * from t2 where t2.a in (select t1.a from t1,t3 where t1.b=t3.a);
|
||||
explain select * from t2 where t2.a in (select t1.a from t1,t3 where t1.b=t3.a);
|
||||
drop table t1, t2, t3;
|
||||
|
||||
Reference in New Issue
Block a user