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 ...
下面是我update数据库时打印出来的异常:
Cause: 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 'in (
'1'
)' at line 1
错误分析:
MySQL语法错误,并且是在第一行的“ in ('1')' ” 的附近检查。
查找错误:

上面的SQL语句
是错误的,这里不应该有“=”。
解决办法:
删除这个“=”号即可。
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 ...的更多相关文章
- 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 'like '%逸%'' at line 1
<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE mapper PUBLIC "-/ ...
- 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 t1,customer t2
### SQL: select t1.gid,t1.gname,t1.gvalue,t1.gtype, t1.gaddress,t1.gmembers, t1.gcode,t1.gphone, t2. ...
- mybatis批量更新update-设置多个字段值 报错 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
mybatis批量更新update-设置多个字段值 2016年08月01日 12:49:26 姚一号 阅读数:29539 标签: mysql mybatis批量更新批量更新allowMultiQuer ...
- ERROR: 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 'type=InnoDB' at line 7
问题: 使用hibernate4.1.1,数据库使用mysql5.1.30,使用hibernate自动生成数据库表时,hibernate方言使用org.hibernate.dialect.MySQLI ...
- C# Mysql 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 ????
有几年没用过MySql数据了,今天在使用C#访问MySql数据库时出现了一个小插曲. 错误提示: You have an error in your SQL syntax; check the man ...
- 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
关于用Power Designer 生成sql文件出现 错误 [Err] 1064 - You have an error in your SQL syntax; check the manual ...
- 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 '
mysql中如果字段使用了关键字,在插入和更新时会提示 You have an error in your SQL syntax; check the manual that corresponds ...
- 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 'groups)VALUES('1','hh','hh@163.com','Boss')' at line 1
mysql8.0版本 在已存在的表里插入一条数据 insert INTO api_user(id,username,email,groups)VALUES('1','hh','hh@163.com', ...
- 解决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 'order (order_name, customer)
在学习hibernate一对多映射关系时,根据视频学习的时候,例子是顾客和订单的问题,一个顾客有多个订单.按照视频中的敲代码出现了You have an error in your SQL synta ...
随机推荐
- LAMP学习小记
记录今天学习到的解决LAMP环境搭建的两个小问题: 问题1.xshell无法连接到虚拟机上的linux主机 解决方法: (1)进入网络配置文件: vi /etc/sysconfig/network-s ...
- Java变量&&简单程序流程&&循环
变量:强类型局部变量: 1.先赋值,后使用 2.作用范围:从定义开始,到所在代码块结束 3.重合范围内不允许重复命名 数据类型(8中基本类型) byte 1B -128~127 short 2B -3 ...
- 关于jquery尺寸的总结
以前总是对jquery的尺寸稀里糊涂,有需要的可以看下下面的代码: ①页面布局如下: <!doctype html> <html> <head> <meta ...
- js加密
在项目中,经常需要使用加密来保障数据的安全性,虽然可以通过在后台加密再传给前台,但这样无疑会增加后台的服务器的压力.所以在js中使用加密算法也就应运而生了. 一.base64加密 需要引入base64 ...
- 关于H5里的API,上传图片预览功能
FileReader:读取本地图片文件并显示 写在开头 之前公司要求做一个H5页面,功能是照相和选择相册相片,并且能在屏幕上预览.然后我就傻里吧唧的各种找插件,因为有些插件不适配手机的型号,安卓机基本 ...
- PHP结合memcacheq消息队列解决并发问题
在处理业务逻辑时有可能遇到高并发问题,例如商城秒杀.微博评论等.如果不做任何措施可能在高瞬间造成服务器瘫痪,如何解决这个问题呢?队列是个不错的选择.队列(Queue)又称先进先出(First In F ...
- hibernate系列笔记(2)---Hibernate的核心API
Hibernate的核心API 一般我们通过hibernate进行操作的时候,都会遵循下面的流程,那么接下来我对每一个步骤进行讲解: 1 public void testInsert() { 2 // ...
- JS排序算法
1.冒泡排序 冒泡算法是比较相邻的两项,如果前者比后者大,就交换他们. 假设一共有n项,那么一共需要n-1趟,第一趟需要交换n-1次,但是第一趟结束后,最后一项基本确定就是最大项了,所以第二次需要交换 ...
- 【Zookeeper】源码分析之服务器(二)
一.前言 前面阐述了服务器的总体框架,下面来分析服务器的所有父类ZooKeeperServer. 二.ZooKeeperServer源码分析 2.1 类的继承关系 public class ZooKe ...
- 设置node服务器的端口及运行环境
一般来说,node服务器中通常会看到这样的代码: ``` app.set('port', process.env.PORT || 3000); if ( process.env.NODE_ENV == ...