From 607852cf47e39927d9b96ff419b336ee6823d48a Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 26 Jul 2005 12:18:35 +0500 Subject: a fix (bug #11546: Bad error message from inserting out of range values, SQL_MODE='tradition'). sql/field.cc: a fix (bug #11546: Bad error message from inserting out of range values, SQL_MODE='tradition'). raise an error in case of strict mode for bit fields. --- mysql-test/t/strict.test | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'mysql-test/t/strict.test') diff --git a/mysql-test/t/strict.test b/mysql-test/t/strict.test index 71b57424e75..9e8d92533d9 100644 --- a/mysql-test/t/strict.test +++ b/mysql-test/t/strict.test @@ -1118,3 +1118,14 @@ insert into t1 values ('2000-10-01'); update t1 set d = 1100; select * from t1; drop table t1; + +# +# BIT fields +# + +set @@sql_mode='traditional'; +create table t1(a bit(2)); +--error 1406 +insert into t1 values(b'101'); +select * from t1; +drop table t1; -- cgit v1.2.1