diff options
author | unknown <ibabaev@bk-internal.mysql.com> | 2007-02-13 23:35:06 +0100 |
---|---|---|
committer | unknown <ibabaev@bk-internal.mysql.com> | 2007-02-13 23:35:06 +0100 |
commit | 579c926de004af406ce6aa3f2eae84c9cdf0781b (patch) | |
tree | e7c9c5ef34c15e106ecfffeae09f22401013ba30 /mysql-test/r/select.result | |
parent | e5c1656e978894d3c021ce4e702c9e03ef0fe7ca (diff) | |
parent | e656c582bc68ed708e2a74c78487cca5528907e1 (diff) | |
download | mariadb-git-579c926de004af406ce6aa3f2eae84c9cdf0781b.tar.gz |
Merge bk-internal.mysql.com:/data0/bk/mysql-5.0
into bk-internal.mysql.com:/data0/bk/mysql-5.0-opt
BitKeeper/etc/gone:
auto-union
mysys/my_getopt.c:
Auto merged
sql/field.h:
Auto merged
sql/item.cc:
Auto merged
sql/item_cmpfunc.cc:
Auto merged
sql/item_cmpfunc.h:
Auto merged
sql/mysql_priv.h:
Auto merged
sql/sql_prepare.cc:
Auto merged
sql/sql_select.cc:
Auto merged
sql/table.cc:
Auto merged
mysql-test/r/select.result:
Manual merge
mysql-test/t/select.test:
Manual merge
Diffstat (limited to 'mysql-test/r/select.result')
-rw-r--r-- | mysql-test/r/select.result | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/mysql-test/r/select.result b/mysql-test/r/select.result index 702ac39cb95..3c4df47ca7b 100644 --- a/mysql-test/r/select.result +++ b/mysql-test/r/select.result @@ -3728,6 +3728,34 @@ WHERE ID_better=1 AND ID1_with_null IS NULL AND id select_type table type possible_keys key key_len ref rows Extra 1 SIMPLE t1 ref idx1,idx2 idx2 4 const 1 Using where DROP TABLE t1; +CREATE TABLE t1 (a INT, ts TIMESTAMP, KEY ts(ts)); +INSERT INTO t1 VALUES (30,"2006-01-03 23:00:00"), (31,"2006-01-03 23:00:00"); +ANALYZE TABLE t1; +Table Op Msg_type Msg_text +test.t1 analyze status OK +CREATE TABLE t2 (a INT, dt1 DATETIME, dt2 DATETIME, PRIMARY KEY (a)); +INSERT INTO t2 VALUES (30, "2006-01-01 00:00:00", "2999-12-31 00:00:00"); +INSERT INTO t2 SELECT a+1,dt1,dt2 FROM t2; +ANALYZE TABLE t2; +Table Op Msg_type Msg_text +test.t2 analyze status OK +EXPLAIN +SELECT * FROM t1 LEFT JOIN t2 ON (t1.a=t2.a) WHERE t1.a=30 +AND t1.ts BETWEEN t2.dt1 AND t2.dt2 +AND t1.ts BETWEEN "2006-01-01" AND "2006-12-31"; +id select_type table type possible_keys key key_len ref rows Extra +1 SIMPLE t2 const PRIMARY PRIMARY 4 const 1 +1 SIMPLE t1 range ts ts 4 NULL 1 Using where +Warnings: +Warning 1292 Incorrect datetime value: '2999-12-31 00:00:00' for column 'ts' at row 1 +SELECT * FROM t1 LEFT JOIN t2 ON (t1.a=t2.a) WHERE t1.a=30 +AND t1.ts BETWEEN t2.dt1 AND t2.dt2 +AND t1.ts BETWEEN "2006-01-01" AND "2006-12-31"; +a ts a dt1 dt2 +30 2006-01-03 23:00:00 30 2006-01-01 00:00:00 2999-12-31 00:00:00 +Warnings: +Warning 1292 Incorrect datetime value: '2999-12-31 00:00:00' for column 'ts' at row 1 +DROP TABLE t1,t2; create table t1 (a bigint unsigned); insert into t1 values (if(1, 9223372036854775808, 1)), @@ -3758,3 +3786,4 @@ coalesce(cast(1111111111111111111 as unsigned), 1) co; i c co 1111111111111111111 1111111111111111111 1111111111111111111 End of 5.0 tests + |