`
sillycat
  • 浏览: 2566525 次
  • 性别: Icon_minigender_1
  • 来自: 成都
社区版块
存档分类
最新评论

Mysql Database Event and Procedure(3)Stored Procedure

 
阅读更多
Mysql Database Event and Procedure(3)Stored Procedure

Grammar
create procedure Name()
(
[in|out|inout] variable datatype
)
begin
     mysql statements;
end;

examples:
CREATE procedure p2(p INT) SET @x = p;

CALL p2(123);

SELECT @X;

define procedure, set user variable in procedure; call procedure; select the user variable

Comments
/* this is comments
   across multiple lines
*/
- - single line comments

This blog can be used as reference for grammar
https://yq.aliyun.com/articles/20804

References:
http://www.jianshu.com/p/1cb06d5eda09
https://yq.aliyun.com/articles/20804
分享到:
评论

相关推荐

    Navicat Premium Enterprise Edition v10.0.10 + Keygen

    Navicat Premium combines the functions of other Navicat members and supports most of the features in MySQL, SQL Server, SQLite, Oracle and PostgreSQL including Stored Procedure, Event, Trigger, ...

    mysql文档教程

    - 视图(View)和存储过程(Stored Procedure) - 事务处理(Transaction)与隔离级别 - 触发器(Trigger)和事件(Event) - 复制(Replication)和高可用性解决方案 - 性能优化,如索引(Index)、查询优化和性能...

    PremiumSoft Navicat Premium Enterprise v11.2.13 (x86 & x64)

    Navicat Premium combines the functions of other Navicat members and supports most of the features in MySQL, SQL Server, SQLite, Oracle and PostgreSQL including Stored Procedure, Event, Trigger, ...

    Navicat 11.2.12 Premium x64

    Navicat Premium combines the functions of other Navicat members and supports most of the features in MySQL, SQL Server, SQLite, Oracle and PostgreSQL including Stored Procedure, Event, Trigger, ...

    Sql for mysql

    1.2 Database, Database Server, and Database Language. . . . . . . . . 4 1.3 The Relational Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 1.4 What Is SQL? . . . . . . . . . ...

    Delphi7.1 Update

    Using collections containing component references and form inheritance can result in incorrect references being stored in the dfm file.======================================================= CORE ...

    Pb常用概念与术语及script编程规范

    PB支持五种主要的数据源类型:QUICKSELECT、SQLSELECT、QUERY、EXTERNAL 和 STORED PROCEDURE。其中QUICKSELECT和SQLSELECT分别用于快速选择和执行SQL语句;QUERY则更灵活,支持复杂的查询结构;EXTERNAL表示外部...

Global site tag (gtag.js) - Google Analytics