码迷,mamicode.com
首页 > 其他好文 > 详细

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

时间:2017-05-09 20:43:33      阅读:905      评论:0      收藏:0      [点我收藏+]

标签:out   code   logs   state   line   blog   tab   ted   deposit   

org.springframework.dao.DataIntegrityViolationException: 
### Error updating database.  Cause: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Out of range value for column ‘id‘ at row 1
### The error may involve com.baomidou.springwind.mapper.ActivityMapper.insert-Inline
### The error occurred while setting parameters
### SQL: INSERT INTO activity   ( id,  title,  tag,  content,      `state`,    add_time,  update_time,  places,  deposit,  full_price )  VALUES   ( ?,  ?,  ?,  ?,      ?,    ?,  ?,  ?,  ?,  ? )
### Cause: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Out of range value for column ‘id‘ at row 1
; SQL []; Data truncation: Out of range value for column ‘id‘ at row 1; nested exception is com.mysql.jdbc.MysqlDataTruncation: Data truncation: Out of range value for column ‘id‘ at row 1

 

 

解决办法: 数据库 主键id 类型由int改为 bigInt

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

标签:out   code   logs   state   line   blog   tab   ted   deposit   

原文地址:http://www.cnblogs.com/thinkingandworkinghard/p/6832334.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!