diff options
author | unknown <monty@mysql.com> | 2004-03-29 19:21:53 +0300 |
---|---|---|
committer | unknown <monty@mysql.com> | 2004-03-29 19:21:53 +0300 |
commit | ff908d18a27247c3b4206ce49977c4a7c73792be (patch) | |
tree | f51ea3945f84d672edc962cdfc11eab16f569fc5 /mysql-test/r/order_by.result | |
parent | 883215956e1597c7432cb79a68b510a4c0f7c9c2 (diff) | |
parent | 501c3e7a0e1770aa7b40a2b1c19b8e89388b834f (diff) | |
download | mariadb-git-ff908d18a27247c3b4206ce49977c4a7c73792be.tar.gz |
Merge with 4.0 to get lastest bug fixes
include/m_string.h:
Auto merged
myisam/mi_create.c:
Auto merged
mysql-test/r/bdb-crash.result:
Auto merged
sql/handler.h:
Auto merged
mysql-test/r/grant_cache.result:
Auto merged
mysql-test/t/grant_cache.test:
Auto merged
sql/sql_cache.cc:
Auto merged
sql/sql_table.cc:
Auto merged
innobase/mem/mem0dbg.c:
Merge with 4.0
mysql-test/r/myisam.result:
Merge with 4.0
mysql-test/r/order_by.result:
Merge with 4.0
mysql-test/t/bdb-crash.test:
Merge with 4.0
mysql-test/t/myisam.test:
Merge with 4.0
mysql-test/t/order_by.test:
Merge with 4.0
sql/ha_berkeley.cc:
Merge with 4.0 (use local code)
sql/sql_select.cc:
Merge with 4.0 to get fix for FORCE INDEX ... ORDER BY
Diffstat (limited to 'mysql-test/r/order_by.result')
-rw-r--r-- | mysql-test/r/order_by.result | 97 |
1 files changed, 0 insertions, 97 deletions
diff --git a/mysql-test/r/order_by.result b/mysql-test/r/order_by.result index 006b507d409..2e9fe1995d0 100644 --- a/mysql-test/r/order_by.result +++ b/mysql-test/r/order_by.result @@ -546,100 +546,3 @@ a b 1 2 5 NULL DROP TABLE t1; -CREATE TABLE t1 ( -FieldKey varchar(36) NOT NULL default '', -LongVal bigint(20) default NULL, -StringVal mediumtext, -KEY FieldKey (FieldKey), -KEY LongField (FieldKey,LongVal), -KEY StringField (FieldKey,StringVal(32)) -); -INSERT INTO t1 VALUES ('0',3,'0'),('0',2,'1'),('0',1,'2'),('1',2,'1'),('1',1,'3'), ('1',0,'2'),('2',3,'0'),('2',2,'1'),('2',1,'2'),('2',3,'0'),('2',2,'1'),('2',1,'2'),('3',2,'1'),('3',1,'2'),('3','3','3'); -EXPLAIN SELECT * FROM t1 WHERE FieldKey = '1' ORDER BY LongVal; -id select_type table type possible_keys key key_len ref rows Extra -1 SIMPLE t1 ref FieldKey,LongField,StringField LongField 36 const 3 Using where -SELECT * FROM t1 WHERE FieldKey = '1' ORDER BY LongVal; -FieldKey LongVal StringVal -1 0 2 -1 1 3 -1 2 1 -EXPLAIN SELECT * FROM t1 WHERE FieldKey > '2' ORDER BY LongVal; -id select_type table type possible_keys key key_len ref rows Extra -1 SIMPLE t1 range FieldKey,LongField,StringField FieldKey 36 NULL 4 Using where; Using filesort -SELECT * FROM t1 WHERE FieldKey > '2' ORDER BY LongVal; -FieldKey LongVal StringVal -3 1 2 -3 2 1 -3 3 3 -EXPLAIN SELECT * FROM t1 WHERE FieldKey > '2' ORDER BY FieldKey, LongVal; -id select_type table type possible_keys key key_len ref rows Extra -1 SIMPLE t1 range FieldKey,LongField,StringField LongField 36 NULL 4 Using where -SELECT * FROM t1 WHERE FieldKey > '2' ORDER BY FieldKey, LongVal; -FieldKey LongVal StringVal -3 1 2 -3 2 1 -3 3 3 -DROP TABLE t1; -CREATE TABLE t1 (a INT, b INT); -SET @id=0; -UPDATE t1 SET a=0 ORDER BY (a=@id), b; -DROP TABLE t1; -CREATE TABLE t1 ( id smallint(6) unsigned NOT NULL default '0', menu tinyint(4) NOT NULL default '0', KEY id (id), KEY menu (menu)) ENGINE=MyISAM; -INSERT INTO t1 VALUES (11384, 2),(11392, 2); -SELECT id FROM t1 WHERE id <11984 AND menu =2 ORDER BY id DESC LIMIT 1 ; -id -11392 -drop table t1; -create table t1(a int, b int, index(b)); -insert into t1 values (2, 1), (1, 1), (4, NULL), (3, NULL), (6, 2), (5, 2); -explain select * from t1 where b=1 or b is null order by a; -id select_type table type possible_keys key key_len ref rows Extra -1 SIMPLE t1 ref_or_null b b 5 const 3 Using where; Using filesort -select * from t1 where b=1 or b is null order by a; -a b -1 1 -2 1 -3 NULL -4 NULL -explain select * from t1 where b=2 or b is null order by a; -id select_type table type possible_keys key key_len ref rows Extra -1 SIMPLE t1 ref_or_null b b 5 const 4 Using where; Using filesort -select * from t1 where b=2 or b is null order by a; -a b -3 NULL -4 NULL -5 2 -6 2 -drop table t1; -create table t1 (a int not null auto_increment, b int not null, c int not null, d int not null, -key(a,b,d), key(c,b,a)); -create table t2 like t1; -insert into t1 values (NULL, 1, 2, 0), (NULL, 2, 1, 1), (NULL, 3, 4, 2), (NULL, 4, 3, 3); -insert into t2 select null, b, c, d from t1; -insert into t1 select null, b, c, d from t2; -insert into t2 select null, b, c, d from t1; -insert into t1 select null, b, c, d from t2; -insert into t2 select null, b, c, d from t1; -insert into t1 select null, b, c, d from t2; -insert into t2 select null, b, c, d from t1; -insert into t1 select null, b, c, d from t2; -insert into t2 select null, b, c, d from t1; -insert into t1 select null, b, c, d from t2; -optimize table t1; -Table Op Msg_type Msg_text -test.t1 optimize status OK -set @row=10; -insert into t1 select 1, b, c + (@row:=@row - 1) * 10, d - @row from t2 limit 10; -select * from t1 where a=1 and b in (1) order by c, b, a; -a b c d -1 1 2 0 -1 1 12 -1 -1 1 52 -5 -1 1 92 -9 -select * from t1 where a=1 and b in (1); -a b c d -1 1 92 -9 -1 1 52 -5 -1 1 12 -1 -1 1 2 0 -drop table t1, t2; |