summaryrefslogtreecommitdiff
path: root/mysql-test/r/type_float.result
diff options
context:
space:
mode:
authorunknown <msvensson@neptunus.(none)>2006-02-21 14:55:54 +0100
committerunknown <msvensson@neptunus.(none)>2006-02-21 14:55:54 +0100
commitf3c9a47517147dd447f7e668fd1d97c22e2d737a (patch)
tree8bc1e6fcf04a84f6677fb8f4ded5aa099820d477 /mysql-test/r/type_float.result
parentf220f892124878c8ef202b847f292f7f05d83d2e (diff)
downloadmariadb-git-f3c9a47517147dd447f7e668fd1d97c22e2d737a.tar.gz
Bug#11589 mysqltest, --ps-protocol, strange output, float/double/real with zerofill
- Add zerofill in client if real/float/double is bound to string and fetched using binary protocol. libmysql/libmysql.c: Add zerofill before value if column is created with zerofill mysql-test/r/type_float.result: Update test for zerofill mysql-test/t/type_float.test: Add test for zerofill and prepared statments
Diffstat (limited to 'mysql-test/r/type_float.result')
-rw-r--r--mysql-test/r/type_float.result16
1 files changed, 16 insertions, 0 deletions
diff --git a/mysql-test/r/type_float.result b/mysql-test/r/type_float.result
index c10cb7d71f7..a46ff64e0ba 100644
--- a/mysql-test/r/type_float.result
+++ b/mysql-test/r/type_float.result
@@ -244,3 +244,19 @@ create table t1 (s1 float(0,2));
ERROR 42000: For float(M,D), double(M,D) or decimal(M,D), M must be >= D (column 's1').
create table t1 (s1 float(1,2));
ERROR 42000: For float(M,D), double(M,D) or decimal(M,D), M must be >= D (column 's1').
+CREATE TABLE t1 (
+f1 real zerofill,
+f2 double zerofill,
+f3 float zerofill);
+INSERT INTO t1 VALUES ( 0.314152e+1, 0.314152e+1, 0.314152e+1);
+PREPARE stmt1 FROM 'select f1, f2, f3 FROM t1';
+select f1, f2, f3 FROM t1;
+f1 f2 f3
+0000000000000003.14152 0000000000000003.14152 000003.14152
+select f1, f2, f3 FROM t1;
+f1 f2 f3
+0000000000000003.14152 0000000000000003.14152 000003.14152
+EXECUTE stmt1;
+f1 f2 f3
+0000000000000003.14152 0000000000000003.14152 000003.14152
+DROP TABLE t1;