在MySQL中创建带分隔符的存储过程

您可以使用create procedure命令创建存储过程。语法如下 −,登录后复制,将上述语法应用于创建存储过程。查询如下 −,登录后复制,Now you need to change the delimiter with ; to call stored procedure −,登录后复制,You can call stored procedure using CALL command. The syntax is as follows −,登录后复制,The above stored procedure can be called using CALL command as shown in the below query −,登录后复制,以下是输出 −,登录后复制,在上面,我们使用了表格 ‘StoredProcTable’,这个表格有三条记录。使用存储过程显示了所有记录。,您可以使用存储过程检查表格中有多少条记录 –,登录后复制,Call the stored procedure using CALL command. The query is as follows −,登录后复制,以下输出显示记录的计数 −,登录后复制,以上就是在MySQL中创建带分隔符的存储过程的详细内容,更多请关注www.92cms.cn其它相关文章!
返回顶部
跳到底部

Copyright 2011-2024 南京追名网络科技有限公司 苏ICP备2023031119号-6 乌徒帮 All Rights Reserved Powered by Z-BlogPHP Theme By open开发