您好,登錄后才能下訂單哦!
一、通過pls塊來調用存儲過程;
declare
p_dzno varchar2(50);
p_vchtype VARCHAR2(50);
p_productclass VARCHAR2(50);
p_dptcode VARCHAR2(50);
begin
p_vchtype:='MP';
p_productclass:='03';
p_dptcode:='206';
PRODDATA.product_dz_proc.pd_getdzno(p_dzno,p_vchtype,p_productclass,p_dptcode);
DBMS_OUTPUT.put_line(p_dzno);
end;
二、oracle 匿名塊執行sql
declare
CURSOR flag_cur IS select lp.product_code from lxg_product lp;
productInfo flag_cur%ROWTYPE;
flag char(1);
begin
for productInfo in flag_cur loop
select decode(
(select count(g.product_code)
from ahs_policy_product g
where g.product_code=productInfo.product_code
and g.updated_date > date '2015-07-01'
and g.created_by not in ('BIS', 'PTP', 'pacard', 'admin')
and g.created_by not in (select t.um_code from t_ptp_agent_account_info t)
and rownum = 1),0,'N','Y') into flag from dual;
DBMS_OUTPUT.PUT_LINE(productInfo.product_code ||','|| flag);
end loop;
end;
/
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。