java.sql.BatchUpdateException: Incorrect string value: '\xF0\x9D\x94\xB9+)...' for column 'NAME_' at
2017-12-10 17:58
766 查看
插入mysql时遇到问题java.sql.BatchUpdateException: Incorrect string value: ‘\xF0\x9D\x94\xB9+)…’ for column ‘NAME_’ at row 1
原因:
数据库编码错误
解决方法:
一般这种情况是因为我们程序在读取或者写入数据库的时候使用的是UTF_8的编码,但是我们一般在创建数据的时候使用的是latin1,这是数据库默认的编码,所以在创建数据库的时候把便设置成UTF-8,同时排序规则改成utf8_general_ci即可
原因:
数据库编码错误
解决方法:
一般这种情况是因为我们程序在读取或者写入数据库的时候使用的是UTF_8的编码,但是我们一般在创建数据的时候使用的是latin1,这是数据库默认的编码,所以在创建数据库的时候把便设置成UTF-8,同时排序规则改成utf8_general_ci即可
相关文章推荐
- java.sql.BatchUpdateException: Incorrect string value: '\xF0\x9D\x94\xB9+)...' for column 'title' at
- java.sql.BatchUpdateException: Incorrect string value: '\xD6\xD0\xB9\xFA\xB9\xA4...' for column 'con
- java.sql.BatchUpdateException: Incorrect string value: '\xD6\xD0\xB9\xFA\xB9\xA4...' for column 'con
- . Cause: java.sql.SQLException: Incorrect string value: '\xE6\xB5\x8B\xE8\xAF\x95' for column 'name
- Nutch抓取错误——java.sql.BatchUpdateException: Incorrect string value: '\xF2\xA3\xAC\xB7\xEF\xBF.
- java.sql.SQLException: Incorrect string value: '\xE9\x99\xB6\xE4\xBC\x9F...' for column 'name' at ro
- Nutch2.2.1抓取错误——java.sql.BatchUpdateException: Incorrect string value: '\xF2\xA3\xAC\xB7\xEF\xBF.
- jeesite导入数据库错误:java.sql.SQLException: Incorrect string value: '\xE4\xB8\xAD\xE5\x9B\xBD' for column 'name' at row 1问题解决
- MySql系列:中文写入数据库出现错误java.sql.SQLException: Incorrect string value: '\xE5\xxxx' for column 'xxxx' at row 1及其解决方法
- java.sql.SQLException: Incorrect string value: '\xF0\x9F\x98\x8E' for column 'nick' at row 1
- java.sql.SQLException: Incorrect string value: '\xF0\x9F\x98\x8B' for column 'a' at row 1
- [转]java.sql.SQLException: Incorrect string value: '\xF0\x9F\x98\x8E' for column 'nick' at row 1
- java.sql.SQLException: Incorrect string value: '\xF0\x9F\x98\x8E' for column 'nick' at row 1
- JBPM java.sql.BatchUpdateException: Data truncation: Incorrect datetime value: '' for column 'START_
- 表情存储异常--mybatis抛出异常(java.sql.SQLException: Incorrect string value: '\xF0\x9F\x92\x94' for column 'name' at row 1)
- MySql中报错:java.sql.SQLException: Incorrect string value: '\xF0\x9F\x90\xBB' for column
- mysql插入中文数据报错 java.sql.SQLException: Incorrect string value: '\xE5\x90\x88\xE8\xAE\xA1' for column
- java.sql.BatchUpdateException: Data truncation: Data too long for column 'site_name' at row 1
- mysql插入中文数据报错 java.sql.SQLException: Incorrect string value: '\xE5\x90\x88\xE8\xAE\xA1' for column
- java.sql.SQLException: Incorrect string value: '\xE6\x88\x91\xE7\x9A\x84...' for column 'groupName'