Below is the list of changes that have just been committed into a local
5.0 repository of kostja. When kostja does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.1835 05/04/14 15:14:34 konstantin@stripped +2 -0
A test case for Bug#4956 (decimal -> string conversion problem)
mysql-test/t/type_decimal.test
1.22 05/04/14 15:14:27 konstantin@stripped +17 -0
A test case for Bug#4956 "strange result, insert into longtext, parameter
with numeric value" (the bug itself is not repeatable any more).
mysql-test/r/type_decimal.result
1.30 05/04/14 15:14:27 konstantin@stripped +16 -0
Test results (Bug#4956)
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: konstantin
# Host: dragonfly.local
# Root: /media/sda1/mysql/mysql-5.0-4956
--- 1.29/mysql-test/r/type_decimal.result 2005-03-30 05:00:27 -08:00
+++ 1.30/mysql-test/r/type_decimal.result 2005-04-14 15:14:27 -07:00
@@ -748,3 +748,19 @@
i a b
6 -51.40 0.00
drop table t1;
+create table t1 (c1 varchar(100), c2 longtext);
+insert into t1 set c1= 'non PS, 1.0 as constant', c2=1.0;
+prepare stmt from "insert into t1 set c1='PS, 1.0 as constant ', c2=1.0";
+execute stmt;
+set @a=1.0;
+insert into t1 set c1='non PS, 1.0 in parameter', c2=@a;
+prepare stmt from "insert into t1 set c1='PS, 1.0 in parameter ', c2=?";
+execute stmt using @a;
+select * from t1;
+c1 c2
+non PS, 1.0 as constant 1.0
+PS, 1.0 as constant 1.0
+non PS, 1.0 in parameter 1.0
+PS, 1.0 in parameter 1.0
+deallocate prepare stmt;
+drop table t1;
--- 1.21/mysql-test/t/type_decimal.test 2005-03-30 05:00:27 -08:00
+++ 1.22/mysql-test/t/type_decimal.test 2005-04-14 15:14:27 -07:00
@@ -326,3 +326,20 @@
SELECT i, ROUND(SUM(d1), 2) AS a, ROUND(SUM(d2), 2) AS b FROM t1 GROUP BY i
HAVING a <> b;
drop table t1;
+
+#
+# A test case for Bug#4956 "strange result, insert into longtext, parameter
+# with numeric value": ensure that conversion is done identically no matter
+# where the input data comes from.
+#
+create table t1 (c1 varchar(100), c2 longtext);
+insert into t1 set c1= 'non PS, 1.0 as constant', c2=1.0;
+prepare stmt from "insert into t1 set c1='PS, 1.0 as constant ', c2=1.0";
+execute stmt;
+set @a=1.0;
+insert into t1 set c1='non PS, 1.0 in parameter', c2=@a;
+prepare stmt from "insert into t1 set c1='PS, 1.0 in parameter ', c2=?";
+execute stmt using @a;
+select * from t1;
+deallocate prepare stmt;
+drop table t1;
| Thread |
|---|
| • bk commit into 5.0 tree (konstantin:1.1835) BUG#4956 | konstantin | 15 Apr |