diff options
author | unknown <igor@rurik.mysql.com> | 2005-07-28 21:28:20 -0700 |
---|---|---|
committer | unknown <igor@rurik.mysql.com> | 2005-07-28 21:28:20 -0700 |
commit | 48abe1d664a196fedca8964eecc40cd76ae1203b (patch) | |
tree | 0133743f252d5786309a3f6e0655b935d21c7100 /mysql-test/r/null_key.result | |
parent | 90b2daa7133cfab02017ff9ffc44d5e8089c0c31 (diff) | |
parent | 21d2fb6287347659dd6ce5835ddf16cd3be50279 (diff) | |
download | mariadb-git-48abe1d664a196fedca8964eecc40cd76ae1203b.tar.gz |
Manual merge
configure.in:
Auto merged
mysql-test/r/null_key.result:
Auto merged
mysql-test/t/null_key.test:
Auto merged
sql/sql_select.cc:
Auto merged
support-files/mysql.spec.sh:
Auto merged
Diffstat (limited to 'mysql-test/r/null_key.result')
-rw-r--r-- | mysql-test/r/null_key.result | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/mysql-test/r/null_key.result b/mysql-test/r/null_key.result index b9824cc4b81..a74a01de8fb 100644 --- a/mysql-test/r/null_key.result +++ b/mysql-test/r/null_key.result @@ -369,3 +369,63 @@ select * from t1; id id2 1 1 drop table t1; +CREATE TABLE t1 (a int); +CREATE TABLE t2 (a int, b int, INDEX idx(a)); +CREATE TABLE t3 (b int, INDEX idx(b)); +CREATE TABLE t4 (b int, INDEX idx(b)); +INSERT INTO t1 VALUES (1), (2), (3), (4); +INSERT INTO t2 VALUES (1, 1), (3, 1); +INSERT INTO t3 VALUES +(NULL), (NULL), (NULL), (NULL), (NULL), +(NULL), (NULL), (NULL), (NULL), (NULL); +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t4 SELECT * FROM t3; +INSERT INTO t3 SELECT * FROM t4; +INSERT INTO t3 VALUES (2), (3); +ANALYZE table t1, t2, t3; +Table Op Msg_type Msg_text +test.t1 analyze status OK +test.t2 analyze status OK +test.t3 analyze status OK +SELECT COUNT(*) FROM t3; +COUNT(*) +15972 +EXPLAIN SELECT SQL_CALC_FOUND_ROWS * FROM t1 LEFT JOIN t2 ON t1.a=t2.a +LEFT JOIN t3 ON t2.b=t3.b; +id select_type table type possible_keys key key_len ref rows Extra +1 SIMPLE t1 ALL NULL NULL NULL NULL 4 +1 SIMPLE t2 ref idx idx 5 test.t1.a 1 +1 SIMPLE t3 ref idx idx 5 test.t2.b 1 Using index +FLUSH STATUS ; +SELECT SQL_CALC_FOUND_ROWS * FROM t1 LEFT JOIN t2 ON t1.a=t2.a +LEFT JOIN t3 ON t2.b=t3.b; +a a b b +1 1 1 NULL +2 NULL NULL NULL +3 3 1 NULL +4 NULL NULL NULL +SHOW STATUS LIKE "handler_read%"; +Variable_name Value +Handler_read_first 0 +Handler_read_key 6 +Handler_read_next 2 +Handler_read_prev 0 +Handler_read_rnd 0 +Handler_read_rnd_next 5 +SELECT FOUND_ROWS(); +FOUND_ROWS() +4 +DROP TABLE t1,t2,t3,t4; |