summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <sergefp@pslp.mylan>2008-04-22 03:36:24 +0400
committerunknown <sergefp@pslp.mylan>2008-04-22 03:36:24 +0400
commit6b4179ec5b0e3015076b1b492e73abe6499b6d4d (patch)
tree29a07c104c0bbafd7d6bc65a7fc0bc8bcfcfdac0 /mysql-test
parentc481f6b3cf80f471321d2ef4e7c68fe9e6e5d0ca (diff)
parent1c1f0a62e1f68fd39ae7440042699faaffaaf7fe (diff)
downloadmariadb-git-6b4179ec5b0e3015076b1b492e73abe6499b6d4d.tar.gz
Merge mysql.com:/home/psergey/mysql-5.0-bugteam
into mysql.com:/home/psergey/mysql-5.1-bugteam BUG#36139: manual merge sql/item.cc: Auto merged mysql-test/r/subselect.result: BUG#36139: Manual merge mysql-test/t/subselect.test: BUG#36139: Manual merge
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/subselect.result7
-rw-r--r--mysql-test/t/subselect.test12
2 files changed, 19 insertions, 0 deletions
diff --git a/mysql-test/r/subselect.result b/mysql-test/r/subselect.result
index 1ef250aae99..98a8ea43473 100644
--- a/mysql-test/r/subselect.result
+++ b/mysql-test/r/subselect.result
@@ -4339,6 +4339,13 @@ a4 f3 a6
1 NULL NULL
2 NULL NULL
DROP TABLE t1, t2, t3, t4;
+create table t1 (a float(5,4) zerofill);
+create table t2 (a float(5,4),b float(2,0));
+select t1.a from t1 where
+t1.a= (select b from t2 limit 1) and not
+t1.a= (select a from t2 limit 1) ;
+a
+drop table t1;
End of 5.0 tests.
CREATE TABLE t1 (a int, b int);
INSERT INTO t1 VALUES (2,22),(1,11),(2,22);
diff --git a/mysql-test/t/subselect.test b/mysql-test/t/subselect.test
index c86b0fefbdc..566b557a27e 100644
--- a/mysql-test/t/subselect.test
+++ b/mysql-test/t/subselect.test
@@ -3213,6 +3213,18 @@ GROUP BY a4;
DROP TABLE t1, t2, t3, t4;
+#
+# BUG#36139 "float, zerofill, crash with subquery"
+#
+create table t1 (a float(5,4) zerofill);
+create table t2 (a float(5,4),b float(2,0));
+
+select t1.a from t1 where
+ t1.a= (select b from t2 limit 1) and not
+ t1.a= (select a from t2 limit 1) ;
+
+drop table t1;
+
--echo End of 5.0 tests.
#