存储过程返回值

写一个过程,供程序调用,且有返回值
暂时记录此过程,完成后再完善

CREATE OR REPLACE PROCEDURE getUserList(
userid varchar2,
userRow out tbl_user%rowtype )
as
--DECLARE
       --结构定义成公共的外部结构,也可以作返回值用吧?
       TYPE TB_USER_STRUCT IS RECORD(

              userid VARCHAR2(50),

              name VARCHAR2(50),
             
              blog VARCHAR2(50));


       myUser TB_USER_STRUCT;



--userRow tbl_user%rowtype;

begin

      select * into userRow  from tbl_user where userid =userid;
      select * into myUser  from tbl_user where userid =userid;

end;

你可能感兴趣的:(存储过程)