带有入参和出参的存储过程的调用
小沈阳 2011-09-26 01:23:22 CREATE OR REPLACE PROCEDURE WEBHALL_OWNER_USER.WB_mobile_active_cust_number
(
in_start_date IN varchar2, --开始时间
in_end_date IN varchar2, --结束时间
in_report_item in varchar2, -- 统计标示
o_report_value out varchar2, --统计项值
oi_errorFlag OUT number, --1正常 0异常
os_message OUT varchar2 --error Message
)
IS
-- 获得参数 event
vi_value number :=0;
vs_error_message varchar(300);
vi_is_error number:=0; --1正常 0异常
begin
-- 执行SQL
select count(distinct(f_service_id))
into vi_value
from wb_cust_contact_t
where f_contact_result = 1
and f_event = '14'
and f_service_kind = '8'
and f_stat_time>=TO_DATE (in_start_date, 'yyyy-mm-dd hh24:mi:ss')
and f_stat_time<=TO_DATE (in_end_date, 'yyyy-mm-dd hh24:mi:ss');
o_report_value := to_char(vi_value);
oi_errorFlag:=1;
exception
when others then
oi_errorFlag:=0;
os_message := SUBSTR(SQLERRM,1,200);
END WB_mobile_active_cust_number;
/
好久没有用存储过程了,这个存储过程怎么调用啊?我想看看输出参数是什么。