Bug #79997 Truncated incorrect DOUBLE value
Submitted: 15 Jan 2016 6:25 Modified: 15 Jan 2016 19:00
Reporter: lee zhenhua Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:5.7.10 OS:CentOS (x86_64)
Assigned to: CPU Architecture:Any

[15 Jan 2016 6:25] lee zhenhua
Description:
when i create table,the coum of a was int type.

when i use where a is char then find one row   ,Actual this cloumn data is 0 .

mysql> select  * from t1 where a='abc';
+------+
| a    |
+------+
|    0 |
+------+
1 row in set, 1 warning (0.07 sec)

mysql> show warnings//
+---------+------+-----------------------------------------+
| Level   | Code | Message                                 |
+---------+------+-----------------------------------------+
| Warning | 1292 | Truncated incorrect DOUBLE value: 'abc' |
+---------+------+-----------------------------------------+
1 row in set (0.00 sec)

How to repeat:
create table t1 (a int);
insert into t1 values(1);
insert into t1 values(0);

mysql> select  * from t1 where a='abc';
+------+
| a    |
+------+
|    0 |
+------+
1 row in set, 1 warning (0.07 sec)

mysql> show warnings//
+---------+------+-----------------------------------------+
| Level   | Code | Message                                 |
+---------+------+-----------------------------------------+
| Warning | 1292 | Truncated incorrect DOUBLE value: 'abc' |
+---------+------+-----------------------------------------+
1 row in set (0.00 sec)
[15 Jan 2016 19:00] MySQL Verification Team
Thank you for the bug report.  Please read.

http://dev.mysql.com/doc/refman/5.7/en/type-conversion.html