summaryrefslogtreecommitdiff
path: root/mysql-test/t/strict.test
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mariadb.org>2015-09-17 11:05:07 +0400
committerAlexander Barkov <bar@mariadb.org>2015-09-17 11:05:07 +0400
commitd9b25ae3db8584bde809c0ab3230cbe151fa489b (patch)
treecb0ae8c91d4f1bcd614c3c1b2d7847f3ef7a130f /mysql-test/t/strict.test
parentc69cf93bfb3a221d9106f3695aa16e11f7e8b7fb (diff)
downloadmariadb-git-d9b25ae3db8584bde809c0ab3230cbe151fa489b.tar.gz
MDEV-8466 CAST works differently for DECIMAL/INT vs DOUBLE for empty strings
MDEV-8468 CAST and INSERT work differently for DECIMAL/INT vs DOUBLE for a string with trailing spaces
Diffstat (limited to 'mysql-test/t/strict.test')
-rw-r--r--mysql-test/t/strict.test12
1 files changed, 6 insertions, 6 deletions
diff --git a/mysql-test/t/strict.test b/mysql-test/t/strict.test
index 71b625e0843..b1d36447e00 100644
--- a/mysql-test/t/strict.test
+++ b/mysql-test/t/strict.test
@@ -750,7 +750,7 @@ INSERT INTO t1 VALUES ('-101.55');
INSERT INTO t1 VALUES ('-1010.55');
--error 1264
INSERT INTO t1 VALUES ('-100E+1');
---error 1366
+--error WARN_DATA_TRUNCATED
INSERT INTO t1 VALUES ('-100E');
--error 1264
UPDATE t1 SET col1 =col1 * 50000 WHERE col1 =11;
@@ -764,7 +764,7 @@ INSERT INTO t1 (col1) VALUES ('');
#--error 1265
--error 1366
INSERT INTO t1 (col1) VALUES ('a59b');
---error 1366
+--error WARN_DATA_TRUNCATED
INSERT INTO t1 (col1) VALUES ('1a');
INSERT IGNORE INTO t1 (col1) VALUES ('2a');
INSERT IGNORE INTO t1 values (1/0);
@@ -796,9 +796,9 @@ UPDATE t1 SET col1 =col1 * 5000 WHERE col1 > 0;
UPDATE t1 SET col2 =col2 / 0 WHERE col2 > 0;
--error 1365
UPDATE t1 SET col2= MOD(col2,0) WHERE col2 > 0;
---error 1265
+--error ER_TRUNCATED_WRONG_VALUE_FOR_FIELD
INSERT INTO t1 (col1) VALUES ('');
---error 1265
+--error ER_TRUNCATED_WRONG_VALUE_FOR_FIELD
INSERT INTO t1 (col1) VALUES ('a59b');
--error 1265
INSERT INTO t1 (col1) VALUES ('1a');
@@ -830,9 +830,9 @@ UPDATE t1 SET col1 =col1 * 5000 WHERE col1 > 0;
UPDATE t1 SET col2 =col2 / 0 WHERE col2 > 0;
--error 1365
UPDATE t1 SET col2= MOD(col2,0) WHERE col2 > 0;
---error 1265
+--error ER_TRUNCATED_WRONG_VALUE_FOR_FIELD
INSERT INTO t1 (col1) VALUES ('');
---error 1265
+--error ER_TRUNCATED_WRONG_VALUE_FOR_FIELD
INSERT INTO t1 (col1) VALUES ('a59b');
--error 1265
INSERT INTO t1 (col1) VALUES ('1a');