mysql> insert into t1 values (-129), (-128), (127),(128);
ERROR 1264 (22003): Out of range value for column 'x' at row 1

原因:

新版本的MySQL对字段的严格检查

解决

把my.cnf中的

sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES

改为

sql_mode=NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION

重新启动MySQL。
以后写sql语句时,类型和值最好严格一些

mysql ERROR 1264 (22003): Out of range value for column 'x' at row 1 错误的更多相关文章

  1. Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Out of range value for column 'phone' at row 1

    Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Out of range value for column 'phone ...

  2. Data truncation: Out of range value for column 'id' at row 1 ### The

    org.springframework.dao.DataIntegrityViolationException: ### Error updating database. Cause: com.mys ...

  3. Data truncation: Out of range value for column 'quanity' at row 问题解决方案

    由于之前在自己电脑上搭建了mysql 5.6的数据库,但是在服务器上搭建的是mysql 5.7的环境,在运行过程中出现了如下错误: Data truncation: Out of range valu ...

  4. Data truncation: Out of range value for column 'Quality' at row 1

    Q: Data truncation: Out of range value for column 'Quality' at row 1 com.mysql.jdbc.MysqlDataTruncat ...

  5. 数据库报错com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'ua' at row 1

    记一次报错记录,成长路上的点滴 明明使用浏览器或者微信开发工具调试接口没有问题,但是在真机测试时候就出问题了.(((¬_¬)) 500服务器内部错误,要死的节奏啊 登陆tomcat服务器 使用命令ta ...

  6. Out of range value for column 'huid' at row

    遇到一个MySQL小问题 Data truncation: Out of range value for column 'huid' at row 1       在数据库某表中字段 “huid” 为 ...

  7. Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'img' at row 1故障

    Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'img' at ro ...

  8. Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Incorrect datetime value: '' for column 'createtime' at row 1...

    之前项目一直好好的,之后电脑重装系统,数据库重新安装了一个5.6版本的,项目jar包丢失了,之后就又重新找了一些jar包倒入,结果运行报错: Caused by: com.mysql.jdbc.Mys ...

  9. mysql修改字段长度及pymysql.err.DataError: (1406, "Data too long for column 'name' at row 1")错误

    文章链接:修改字段:https://blog.csdn.net/xiejunna/article/details/78580682 错误分析:https://blog.csdn.net/qq_4214 ...

随机推荐

  1. Idea上配置btm

    1.  先在eclipse中配置好项目,再讲配置好的项目导入到idea中

  2. 随机算法 - HNU 13348 Finding Lines

    Finding Lines Problem's Link: http://acm.hnu.cn/online/?action=problem&type=show&id=13348&am ...

  3. thinkphp 如何调用百度echarts 数据报表插件

    echarts官网网址:http://echarts.baidu.com/ echarts源码地址:http://echarts.baidu.com/build/echarts-2.2.7.zip   ...

  4. 关于Cocos2d-x开发一个游戏的过程自述

    我在2016年12月6号完成了我的第一个自己独立完成的游戏,期间遇到各种各样的问题和困难,但是幸运的是问题都一一被解决了,现在我想总结一个整个的制作游戏的过程 使用的环境是VS2013+cocos2d ...

  5. 在JAVA中利用public static final的组合方式对常量进行标识

    在JAVA中利用public static final的组合方式对常量进行标识(固定格式). 对于在构造方法中利用final进行赋值的时候,此时在构造之前系统设置的默认值相对于构造方法失效. 常量(这 ...

  6. 解决 Failure to transfer * from http://repo1.maven.org/maven2

    解决 Failure to transfer * from http://repo1.maven.org/maven2 Failure to transfer org.apache.maven:mav ...

  7. C#正则表达式操作中使用LINQ

    比如:[程序员][代码]博客园 - 程序员的网上家园,代码改变世界 提取出来的Tag应该是:[程序员].[代码] Regex _regexTag = new Regex(@"^(\[[^\] ...

  8. Android 全局异常处理(二)

    CrashHandler  package org.wp.activity; import java.io.File; import java.io.FileOutputStream; import ...

  9. Animate a custom Dialog,自定义Dialog动画

    Inside res/style.xml <style name="AppTheme" parent="android:Theme.Light" /> ...

  10. Arduino开发版学习计划--蓝牙控制小车行走

    蓝牙模块一共6个引脚,我们一般只需要接4个线就可以了,分别是VCC.GND.TXD.RXD这四个引脚,我们分别接到arduino板子上,VCC接3.3V,GND接板子的GND,蓝牙TXD接板子的RXD ...