summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <serg@serg.mylan>2004-02-28 11:24:49 +0100
committerunknown <serg@serg.mylan>2004-02-28 11:24:49 +0100
commit31531bfae5aa3e5006ccf063db2f270aaa3ba9d3 (patch)
tree50c9c95b33aa46e7ab271d274b281283a0dbe4bd
parent30a8a6523856579caf1c61c531a624847819f675 (diff)
downloadmariadb-git-31531bfae5aa3e5006ccf063db2f270aaa3ba9d3.tar.gz
make func_misc portable
on different systems sprintf("%.3", 1.555499999999999) behaves differently
-rw-r--r--mysql-test/r/func_misc.result6
-rw-r--r--mysql-test/t/func_misc.test2
2 files changed, 4 insertions, 4 deletions
diff --git a/mysql-test/r/func_misc.result b/mysql-test/r/func_misc.result
index 581bc54db18..9400c3b9d6b 100644
--- a/mysql-test/r/func_misc.result
+++ b/mysql-test/r/func_misc.result
@@ -1,6 +1,6 @@
-select format(1.5555,0),format(123.5555,1),format(1234.5555,2),format(12345.5555,3),format(123456.5555,4),format(1234567.5555,5),format("12345.2399",2);
-format(1.5555,0) format(123.5555,1) format(1234.5555,2) format(12345.5555,3) format(123456.5555,4) format(1234567.5555,5) format("12345.2399",2)
-2 123.6 1,234.56 12,345.555 123,456.5555 1,234,567.55550 12,345.24
+select format(1.5555,0),format(123.5555,1),format(1234.5555,2),format(12345.55555,3),format(123456.5555,4),format(1234567.5555,5),format("12345.2399",2);
+format(1.5555,0) format(123.5555,1) format(1234.5555,2) format(12345.55555,3) format(123456.5555,4) format(1234567.5555,5) format("12345.2399",2)
+2 123.6 1,234.56 12,345.556 123,456.5555 1,234,567.55550 12,345.24
select inet_ntoa(inet_aton("255.255.255.255.255.255.255.255"));
inet_ntoa(inet_aton("255.255.255.255.255.255.255.255"))
NULL
diff --git a/mysql-test/t/func_misc.test b/mysql-test/t/func_misc.test
index 9759127b222..adc0a5a9263 100644
--- a/mysql-test/t/func_misc.test
+++ b/mysql-test/t/func_misc.test
@@ -2,7 +2,7 @@
# Testing of misc functions
#
-select format(1.5555,0),format(123.5555,1),format(1234.5555,2),format(12345.5555,3),format(123456.5555,4),format(1234567.5555,5),format("12345.2399",2);
+select format(1.5555,0),format(123.5555,1),format(1234.5555,2),format(12345.55555,3),format(123456.5555,4),format(1234567.5555,5),format("12345.2399",2);
select inet_ntoa(inet_aton("255.255.255.255.255.255.255.255"));
select inet_aton("255.255.255.255.255"),inet_aton("255.255.1.255"),inet_aton("0.1.255");