#1064 - You have an error in your SQL syntax; version for the right syntax to use near '' at line
#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 '' at line 33
初次写MySQL的存储过程的时候,以为和其他数据库的存储过程一样,先写完了sql,再放入存储过程就可以了.但是mysql的时候,就碰壁了,如一下的sql是没有问题的
create procedure proc_name
beginselect * from table_name;
end
奈何我的sql里有嵌套的如
create procedure proc_name
beginupdate table_name a,(select b.id,b.name from b -- 这里有复杂的嵌套,只是简单写) bset a.isOvertime=b.isOvertime where a.id=b.id;
end
这样就会报错了,网上找了好久终于找到解决方案
DROP PROCEDURE IF EXISTS proc_name;
DELIMITER //
create procedure proc_name
beginupdate table_name a,(select b.id,b.name from b -- 这里有复杂的嵌套,只是简单写) bset a.isOvertime=b.isOvertime where a.id=b.id;
end //
DELIMITER ;
MySQL语句默认分隔符为分号; 我们先就是定义新的分隔符//, 然后存储过程内的分号;就不会影响,存储过程结束再恢复分隔符为;
MYSQL存储过程
#1064 - You have an error in your SQL syntax; version for the right syntax to use near '' at line相关推荐
- SQL查询1064报错 [ERR] 1064 - You have an error in your SQL syntax; check the manual.......
MySQL建表出现1064问题问题 SQL语句 DROP DATABASE IF EXISTS bookstore; DROP DATABASE bookstore; USE bookstore; C ...
- centos7 mysql 1064_【mysql报错】1064 - You have an error in your SQL syntax;
mysql 报错1064 - You have an error in your SQL syntax;https://www.cndba.cn/debimeng/article/3198 数据库版本 ...
- 报错,> 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL
错误: idea: 2020-12-23 15:26:13.885 ERROR 17972 --- [MessageBroker-2] o.h.engine.jdbc.spi.SqlException ...
- 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 ...
- MySql 建表出现的问题:[ERR] 1064 - You have an error in your SQL syntax; check the manual..........
使用 MySql 建表出现的问题 在使用 Navicat Premium 运行 sql 语句进行建表时,MySQL 报错如下: 建表语句: DROP DATABASE IF EXISTS javawe ...
- 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 ...
- [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 ...
- mysql报错系列持续整理1064 - You have an error in your SQL syntax;...near...
前言 怎么又是这个错,感觉似曾相识之前遇到过多次了.是的这就是mysql语句报错1064 - You have an error in your SQL .syntax;...near...感觉每次不 ...
- Django >python manage.py migrate报错:(1064, “You have an error in your SQL syntax
执行如下命令时报错(迁移数据库和表结构): python manage.py makemigrations python manage.py migrate 报错信息: django.db.migra ...
最新文章
- Go对Python产生的冲击
- 目前学什么专业的人在搞SLAM?各有什么优势?
- ICML2020 | GCNII:使用初始残差和恒等映射解决过度平滑
- CentOS7.2 安装Docker
- prism项目搭建 wpf_WPF Step By Step 系列-Prism框架在项目中使用
- redis集群的几种模式
- Kafka 配置说明
- linux umount 时出现device is busy 的处理方法--fuser
- STL(四)——map映射
- java I O类大全_Java I/O —— File类
- Waymo无人出租车年底发射,现已进入定价环节 | 公交部门竟成友军?
- 移动物联卡资费标准是如何的
- liunx 下mysql 的安装(转载)
- java中map、list转json
- python接口自动化3-自动发帖(session)
- ccproxy如何设置
- 高德地图定位误差_高德地图定位api以及导航和定位 位置的偏差
- 第五次作业+度盘下载器
- 数据库上机实验一、二
- 宋体能力从业的一些感悟
热门文章
- eBPF BCC 实现UNIX socket抓包
- Linux-5.10.13内核完全注释之工作队列
- Linux系统利用C语言获取网口信息(IP地址,MAC地址,状态,带宽speed等)
- windwos下ffmpeg的安装
- jQuery菜鸟总结
- abap 创建出口历程_SAP ABAP第一,两,三代出口型BADI实现 解释的概念
- java输出 4 7什么意思_Java学习4_一些基础4_输入输出_16.5.7
- shell_exec() php 执行shell脚本
- mysql求和 子查询_MYSQL 查询方法 统计查询 链接查询 子查询
- c语言学习进阶-C语言程序产生正态分布随机数