mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
Some trivial optimzations
Check if AND/OR expression can be NULL; Fixed bug in GROUP BY and-or-expression where expression could be NULL Bug fix for SHOW OPEN TABLES when user didn't have privilege to access all open tables. Better fix for ALTER TABLE on BDB tables.
This commit is contained in:
@@ -1405,9 +1405,9 @@ drop table tmp;
|
||||
|
||||
# big table done
|
||||
|
||||
SET OPTION SQL_BIG_TABLES=1;
|
||||
SET SQL_BIG_TABLES=1;
|
||||
select distinct concat(fld3," ",fld3) as namn from t2,t3 where t2.fld1=t3.t2nr order by namn limit 10;
|
||||
SET OPTION SQL_BIG_TABLES=0;
|
||||
SET SQL_BIG_TABLES=0;
|
||||
select distinct concat(fld3," ",fld3) from t2,t3 where t2.fld1=t3.t2nr order by fld3 limit 10;
|
||||
select distinct fld5 from t2 limit 10;
|
||||
|
||||
@@ -1416,9 +1416,9 @@ select distinct fld5 from t2 limit 10;
|
||||
#
|
||||
|
||||
select distinct fld3,count(*) from t2 group by companynr,fld3 limit 10;
|
||||
SET OPTION SQL_BIG_TABLES=1; # Force use of MyISAM
|
||||
SET SQL_BIG_TABLES=1; # Force use of MyISAM
|
||||
select distinct fld3,count(*) from t2 group by companynr,fld3 limit 10;
|
||||
SET OPTION SQL_BIG_TABLES=0;
|
||||
SET SQL_BIG_TABLES=0;
|
||||
select distinct fld3,repeat("a",length(fld3)),count(*) from t2 group by companynr,fld3 limit 100,10;
|
||||
|
||||
#
|
||||
@@ -1439,6 +1439,14 @@ select distinct fld3 from t2,t3 where t2.companynr = 34 and t2.fld1=t3.t2nr orde
|
||||
|
||||
explain select t3.t2nr,fld3 from t2,t3 where t2.companynr = 34 and t2.fld1=t3.t2nr order by t3.t2nr,fld3;
|
||||
|
||||
#
|
||||
# Some test with ORDER BY and limit
|
||||
#
|
||||
|
||||
explain select * from t3 as t1,t3 where t1.period=t3.period order by t3.period;
|
||||
explain select * from t3 as t1,t3 where t1.period=t3.period order by t3.period limit 10;
|
||||
explain select * from t3 as t1,t3 where t1.period=t3.period order by t1.period limit 10;
|
||||
|
||||
#
|
||||
# Search with a constant table.
|
||||
#
|
||||
|
||||
Reference in New Issue
Block a user