CREATE PROC P_TEST@Name VARCHAR(20),@Rowcount INT OUTPUTASBEGIN SELECT * FROM T_Customer WHERE [email protected] SET @[email protected]@ROWCOUNTENDGO------------------------------------------------------------------------------------------存储过程调用如下:-
创建函数: 格式:create or replace function func(参数 参数类型) Return number Is Begin --------业务逻辑--------- End; --创建函数 create or replace function func (dno number) return number is t_max number; begin select max(sal) into t_max from emp t where deptno = dno; ret
PHP调用MYSQL存储过程实例 来源: http://blog.csdn.net/ewing333/article/details/5906887 实例一:无参的存储过程 $conn = mysql_connect('localhost','root','root') or die ("数据连接错误!!!"); mysql_select_db('test',$conn); $sql = " create procedure myproce() begin INSERT IN