summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <holyfoot/hf@mysql.com/hfmain.(none)>2007-03-22 12:26:32 +0400
committerunknown <holyfoot/hf@mysql.com/hfmain.(none)>2007-03-22 12:26:32 +0400
commit23354862f03692361ffad39b86faef07df9fd74c (patch)
tree13cd3eada91150e49b73f73913f717f5d34b1fd5 /mysql-test
parent1fdab610a23080f92b1af13a597964dea2679073 (diff)
parent50b5064ccd0af957080d9c9efd022e33c7c9c060 (diff)
downloadmariadb-git-23354862f03692361ffad39b86faef07df9fd74c.tar.gz
Merge mysql.com:/home/hf/work/mrg/mysql-4.1-opt
into mysql.com:/home/hf/work/mrg/mysql-5.0-opt mysql-test/t/type_datetime.test: Auto merged mysql-test/r/type_datetime.result: SCCS merged sql/item_timefunc.h: SCCS merged
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/type_datetime.result3
-rw-r--r--mysql-test/t/type_datetime.test6
2 files changed, 9 insertions, 0 deletions
diff --git a/mysql-test/r/type_datetime.result b/mysql-test/r/type_datetime.result
index 7fc1c4f398d..a9083b29805 100644
--- a/mysql-test/r/type_datetime.result
+++ b/mysql-test/r/type_datetime.result
@@ -168,6 +168,9 @@ dt
0000-00-00 00:00:00
0000-00-00 00:00:00
drop table t1;
+select cast('2006-12-05 22:10:10' as datetime) + 0;
+cast('2006-12-05 22:10:10' as datetime) + 0
+20061205221010.000000
CREATE TABLE t1(a DATETIME NOT NULL);
INSERT INTO t1 VALUES ('20060606155555');
SELECT a FROM t1 WHERE a=(SELECT MAX(a) FROM t1) AND (a="20060606155555");
diff --git a/mysql-test/t/type_datetime.test b/mysql-test/t/type_datetime.test
index 3ad6bdc53e4..3d04eb85cf3 100644
--- a/mysql-test/t/type_datetime.test
+++ b/mysql-test/t/type_datetime.test
@@ -113,6 +113,12 @@ insert into t1 values ("00-00-00"), ("00-00-00 00:00:00");
select * from t1;
drop table t1;
+#
+# Bug #16546 DATETIME+0 not always coerced the same way
+#
+select cast('2006-12-05 22:10:10' as datetime) + 0;
+
+
# End of 4.1 tests
#