You have an error in your SQL syntax; check the manual that corresponds to your MySQL server versio
2017-05-17 19:09
736 查看
偶遇一朋友的一个bug,这个朋友在设计数据库的时候将表名设置成了一个关键字“group”,在后期的编程中遇到了这个问题。
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your
MySQL server version for the right syntax to use near 'group limit 0,5' at line 1
报错代码:
String sql = "select * from group limit ?,?";
解决措施:1` 更改表名;
2` 需要把 group 用撇号`括起来,就是键盘上数据1左边的那个键.
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: You have an error in your SQL syntax; check the manual that corresponds to your
MySQL server version for the right syntax to use near 'group limit 0,5' at line 1
报错代码:
String sql = "select * from group limit ?,?";
解决措施:1` 更改表名;
2` 需要把 group 用撇号`括起来,就是键盘上数据1左边的那个键.
相关文章推荐
- *You have an error in your SQL syntax; check the manual that corresponds to your MySQL server versio
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server versio
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server versio
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server versio
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- SQL Error: 1064, SQLState: 42000 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server ve
- java.sql.SQLException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for
- ssh开发中插入数据时遇到 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- MySql 执行语句错误 Err] 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- 插入mysql语句报错:1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- 创建存储过程错误(已解决):Error Code : 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server ver
- You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
- 错误信息:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server ve