错误: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 ‘’ at line 1

今天在运行项目的时候报了一个关于sql的错误:

关于这种错误,首先就要去查看自己的sql语句是否正确

问题排查:

这是原来的代码,发现sql语句竟然多写了一个逗号。

@Overridepublic int delete(int oOrderNum) {String sql = "delete from allOrders where oOrderNumber=?,";return template.update(sql,oOrderNum);}

解决方案:

把逗号删除后就解决并完美运行了。

@Overridepublic int delete(int oOrderNum) {String sql = "delete from allOrders where oOrderNumber=?";return template.update(sql,oOrderNum);}

功能完美运行:


错误:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server vers相关推荐

  1. MyBatis中提示:You have an error in your SQL syntax; check the manual that corresponds to your MySQL ser

    场景 在进行MyBatis查询数据时提示: You have an error in your SQL syntax; check the manual that corresponds to you ...

  2. Hibernate: You have an error in your SQL syntax; check the manual that corresponds to your MySQL

    You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version ...

  3. Error:1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL

    错误代码: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL ser ...

  4. [Err] 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL

    1.MySQL建表报错: [Err] 1064 - You have an error in your SQL syntax; check the manual that corresponds to ...

  5. [Err] 1064 - You have an error in your SQL syntax check the manual that corresponds to 之Mysql报错

    当利用navicat用sql语句建表时候,出现如下报错 从下图我们可以看到,是我们最后一行的末尾多加了一个逗号. 当我们将最后一行的逗号取消掉就正常运行了 特别注意:最后一行的末尾没有逗号. http ...

  6. MySQL建表1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL

    MySQL在导表新建的时候会有索引报错,如下: PRIMARY KEY (`tag_id`) USING BTREE,为导出的SQL语句,但是实际运行时需要改为如下: PRIMARY KEY `tag ...

  7. 数据库工作笔记005---You have an error in your SQL syntax; check the manual that corresponds to y

    JAVA技术交流QQ群:170933152 Query : select * from order LIMIT 0, 1000 Error Code : 1064 You have an error ...

  8. Error Code : 1064 You have an error in your SQL syntax; check the manual that corresponds to your My

    转自:https://blog.csdn.net/haha_66666/article/details/78444457 Query : select * from order LIMIT 0, 10 ...

  9. sql语句异常 You have an error in your SQL syntax; check the manual that corresponds to your.......

    我们在写sql时可能会遇见: You have an error in your SQL syntax; check the manual that corresponds to your-类似这种开 ...

最新文章

  1. Shell脚本文件操作
  2. Algs4-2.2.29自然的归并排序(未解决)
  3. 计算机光盘工作原理,CD-ROM的工作原理
  4. 动态“神还原”李焕英旧照,用技术致敬每一位妈妈!
  5. import 别名_es6模块 import, export 知识点小结
  6. php做微信小程序登录,php(ThinkPHP)实现微信小程序的登录过程
  7. 节流函数的实现,一次面试题遇到的编程题
  8. 使用ffmpeg进行h.264编码
  9. 深度学习目标检测之 YOLO v1
  10. 海上瓶子下有东西吗_洗衣液瓶子我从来不扔,瓶身这样剪几刀,解决了很多家庭的大烦恼...
  11. 【操作系统】第一章.操作系统引论思维导图
  12. php preg_split 正则截取字符串
  13. swift拖放的按钮如何在后台设置点击事件 www.cnblogs.com/foxting/p/SWIFT.html
  14. think in java bruce eckel_java大师 Bruce Eckel 批评java
  15. C语言 简单实现计算器功能 ·函数指针数组实现计算器
  16. drupal7 分页
  17. Vue脚手架安装详解
  18. writeUP-[第五空间2019 决赛]PWN5(待进一步完善待研究内容)
  19. 【UEFI】---关于BIOS,EIST和PStateCState和CPU主频变化得关系
  20. 通知栏通知不被清除通知所取消

热门文章

  1. openstack_Stein版安装文档
  2. java(11):tomcat简介与使用(上)
  3. Java实现 LeetCode 390 消除游戏
  4. 聊聊Linux IO
  5. Post Office(翻译)
  6. 教你一招,轻松实现heic转换
  7. 查看GPU和GPU驱动版本+GPU驱动版本更新
  8. 单片机c语言实现小灯循环亮1 8个,实现单片机信号灯1-8依次循环点亮的程序怎么写...
  9. 【JZOJ5017】拍苍蝇 题解
  10. 译文:如何建立EMS服务?