首頁  >  文章  >  資料庫  >  mysql 存储过程输入输出参数示例

mysql 存储过程输入输出参数示例

WBOY
WBOY原創
2016-06-07 16:28:51958瀏覽

drop PROCEDURE if exists my_procedure; create PROCEDURE my_procedure(in my_id int,out my_name char) BEGIN select list_name into my_name from aa_list where list_id=my_id; end; call my_procedure(24,@a); select @a;

drop PROCEDURE if exists my_procedure; 
create PROCEDURE my_procedure(in my_id int,out my_name char) 
BEGIN  
 select list_name into my_name from aa_list where list_id=my_id; 
end; 
call my_procedure(24,@a); 
select @a;

陳述:
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn