summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <monty@donna.mysql.fi>2001-05-29 13:46:17 +0300
committerunknown <monty@donna.mysql.fi>2001-05-29 13:46:17 +0300
commit9ad7aedb41feeddc5a872cf330197d6e3efc14ed (patch)
tree7f42d1149eac3fb84c4cbb7810d966b33a86fb72 /mysql-test
parent41dd2aa2b5a2f8b7a5d760bff26e8ceb2ce10fff (diff)
downloadmariadb-git-9ad7aedb41feeddc5a872cf330197d6e3efc14ed.tar.gz
Fixed problems with decimals withing IF()
Force add of FN_LIBCHAR to symlinks on windows Docs/manual.texi: Cleanup & Changelog client/mysqladmin.c: Added quoting for 'drop database' client/mysqlcheck.c: Fixed wrong comment syntax libmysql/net.c: Cleanup mysql-test/mysql-test-run.sh: Better error message. mysql-test/r/func_test.result: test for if() mysql-test/t/func_test.test: test for if() mysys/mf_pack.c: Force add of FN_LIBCHAR to symlinks on windows. sql/item_cmpfunc.cc: Fixed problems with decimals withing IF() sql/mysqlbinlog.cc: Better error messages. sql/sql_repl.cc: Better error messages.
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/mysql-test-run.sh5
-rw-r--r--mysql-test/r/func_test.result2
-rw-r--r--mysql-test/t/func_test.test10
3 files changed, 15 insertions, 2 deletions
diff --git a/mysql-test/mysql-test-run.sh b/mysql-test/mysql-test-run.sh
index ece2e42f40b..0dfdbda701e 100644
--- a/mysql-test/mysql-test-run.sh
+++ b/mysql-test/mysql-test-run.sh
@@ -300,8 +300,9 @@ show_failed_diff ()
echo "-------------------------------------------------------"
$DIFF -c $result_file $reject_file
echo "-------------------------------------------------------"
- echo "Please e-mail the above, along with the output of mysqlbug"
- echo "and any other relevant info to bugs@lists.mysql.com"
+ echo "Please follow the instructions outlined at"
+ echo "http://www.mysql.com/doc/R/e/Reporting_mysqltest_bugs.html"
+ echo "to find the reason to this problem and how to report this."
fi
}
diff --git a/mysql-test/r/func_test.result b/mysql-test/r/func_test.result
index 3dc0fc19848..5d2211baf50 100644
--- a/mysql-test/r/func_test.result
+++ b/mysql-test/r/func_test.result
@@ -34,3 +34,5 @@ this is a 2 2.0
1 1
1 and 0 or 2 2 or 1 and 0
1 1
+sum(if(num is null,0.00,num))
+144.54
diff --git a/mysql-test/t/func_test.test b/mysql-test/t/func_test.test
index 9562ae5f77b..0439a96f077 100644
--- a/mysql-test/t/func_test.test
+++ b/mysql-test/t/func_test.test
@@ -24,3 +24,13 @@ select -1.49 or -1.49,0.6 or 0.6;
select 5 between 0 and 10 between 0 and 1,(5 between 0 and 10) between 0 and 1;
select 1 and 2 between 2 and 10, 2 between 2 and 10 and 1;
select 1 and 0 or 2, 2 or 1 and 0;
+
+#
+# Problem with IF()
+#
+
+drop table if exists t1;
+create table t1 (num double(12,2));
+insert into t1 values (144.54);
+select sum(if(num is null,0.00,num)) from t1;
+drop table t1;