diff options
author | unknown <kaa@polly.(none)> | 2007-12-02 13:49:12 +0300 |
---|---|---|
committer | unknown <kaa@polly.(none)> | 2007-12-02 13:49:12 +0300 |
commit | f7bd0808918d48a581dedec489411a0c195d5e70 (patch) | |
tree | 237bd06c1a04bd89fe2a1bb442674da48f89eb64 /mysql-test/t/insert.test | |
parent | cf4b8f6aa8f8ae7fabd05e88a35471ef46881262 (diff) | |
download | mariadb-git-f7bd0808918d48a581dedec489411a0c195d5e70.tar.gz |
Windows-specific fixes in floating point tests.
mysql-test/t/insert.test:
Windows implements a different rounding rules in printf("%g"), thus we still need to do replace_result
mysql-test/t/variables.test:
We need to do replace_result because variables are printed by another procedure.
sql/field.cc:
Fixed the code to limit the precision to DBL_DIG.
Diffstat (limited to 'mysql-test/t/insert.test')
-rw-r--r-- | mysql-test/t/insert.test | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/mysql-test/t/insert.test b/mysql-test/t/insert.test index 3c150d0c3f6..5cb85d32383 100644 --- a/mysql-test/t/insert.test +++ b/mysql-test/t/insert.test @@ -423,6 +423,9 @@ INSERT INTO t1(a,c) VALUES (-1.87e-2, -1.87e-2); INSERT INTO t1(a,c) VALUES (5000e+0, 5000e+0); INSERT INTO t1(a,c) VALUES (-5000e+0, -5000e+0); +# Expected results are "12.2" and "1.2e+78", but Windows returns "12.3" and +# "1.3e+78" due to different rounding rules +--replace_result 12.3 12.2 1.3e+78 1.2e+78 SELECT * FROM t1; DROP TABLE t1; |