SQL> CREATE OR REPLACE PROCEDURE HelloWorld2 (
2 p_user_name IN VARCHAR2,
3 p_out_val OUT VARCHAR2,
4 p_inout_val IN OUT VARCHAR2
5 ) AS
6 BEGIN
7 dbms_output.put_line('Hello ' || p_user_name || p_inout_val || '!');
8 p_out_val := 'A';
9 p_inout_val := 'B';
10 END HelloWorld2;
11 /
Procedure created.
SQL> DECLARE
2 p_outval VARCHAR2(10);
3 p_inoutval VARCHAR2(10) := '~Hi~';
4 BEGIN
5 HelloWorld2('Edward', p_outval, p_inoutval);
6
7 dbms_output.put_line('p_outval=' || p_outval);
8 dbms_output.put_line('p_inoutval=' || p_inoutval);
9 END;
10 /
Hello Edward~Hi~!
p_outval=A
p_inoutval=B
PL/SQL procedure successfully completed.
========================================================================================================
标准包简单调用
========================================================================================================
--设置打印输出
set serveroutput on;
--执行
declare
ret_md5 varchar2(100) :='';
ret_password varchar2(100) :='';
ret_package_len number :=0;
ret_hw_version varchar2(100) :='';
ret_file_length number :=0;
ret_errorcode NUMBER :=0;
ret_errorname VARCHAR2(100) :='';
begin
FLT_COM.p_find_trem_version_info('FLT.SW.07A.0B.V1.10.442.000',0,ret_md5,ret_password,ret_package_len,ret_hw_version,ret_file_length,ret_errorcode,ret_errorname);
dbms_output.put_line(ret_md5);
dbms_output.put_line(ret_password);
dbms_output.put_line(ret_package_len);
dbms_output.put_line(ret_hw_version);
dbms_output.put_line(ret_file_length);
dbms_output.put_line(ret_errorcode);
dbms_output.put_line(ret_errorname);
end;
--------------------------->>END
2 p_user_name IN VARCHAR2,
3 p_out_val OUT VARCHAR2,
4 p_inout_val IN OUT VARCHAR2
5 ) AS
6 BEGIN
7 dbms_output.put_line('Hello ' || p_user_name || p_inout_val || '!');
8 p_out_val := 'A';
9 p_inout_val := 'B';
10 END HelloWorld2;
11 /
Procedure created.
SQL> DECLARE
2 p_outval VARCHAR2(10);
3 p_inoutval VARCHAR2(10) := '~Hi~';
4 BEGIN
5 HelloWorld2('Edward', p_outval, p_inoutval);
6
7 dbms_output.put_line('p_outval=' || p_outval);
8 dbms_output.put_line('p_inoutval=' || p_inoutval);
9 END;
10 /
Hello Edward~Hi~!
p_outval=A
p_inoutval=B
PL/SQL procedure successfully completed.
========================================================================================================
标准包简单调用
========================================================================================================
--设置打印输出
set serveroutput on;
--执行
declare
ret_md5 varchar2(100) :='';
ret_password varchar2(100) :='';
ret_package_len number :=0;
ret_hw_version varchar2(100) :='';
ret_file_length number :=0;
ret_errorcode NUMBER :=0;
ret_errorname VARCHAR2(100) :='';
begin
FLT_COM.p_find_trem_version_info('FLT.SW.07A.0B.V1.10.442.000',0,ret_md5,ret_password,ret_package_len,ret_hw_version,ret_file_length,ret_errorcode,ret_errorname);
dbms_output.put_line(ret_md5);
dbms_output.put_line(ret_password);
dbms_output.put_line(ret_package_len);
dbms_output.put_line(ret_hw_version);
dbms_output.put_line(ret_file_length);
dbms_output.put_line(ret_errorcode);
dbms_output.put_line(ret_errorname);
end;
--------------------------->>END
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/29119536/viewspace-1147048/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/29119536/viewspace-1147048/