1.PL/SQL Developer調(diào)試
在存儲過程名稱上右鍵選擇Edit:
彈出調(diào)試窗口,和存儲過程編譯錯誤信息:?
?文章來源地址http://www.zghlxwxcb.cn/news/detail-565834.html
2.原因分析
上述報錯原因在于存儲過程的入?yún)⒑统鰠⒍疾荒苤付ù笮『湾e誤使用關(guān)鍵字declare,修改后正確代碼如下:
create procedure BranchBalanceSum(s_date in char)
as
all_balance number;
v_bran_no varchar2(10);
v_bran_name varchar2(30);
cursor c_sum_bal is
select open_branch_no,open_branch_name,sum(a_bal)
from accounts group by open_branch_no,open_branch_name;
begin
open c_sum_bal;
loop
fetch c_sum_bal into v_bran_no,v_bran_name,all_balance;
if c_sum_bal%notfound then --未找到記錄
exit;
end if;
insert into branch_sum
values(v_bran_no,s_date,v_bran_name,all_balance);
end loop;
close c_sum_bal;
commit;
exception --異常處理
when others then
rollback;
end;
?文章來源:http://www.zghlxwxcb.cn/news/detail-565834.html
?
到了這里,關(guān)于PL/SQL Developer調(diào)試與存儲過程編譯錯誤:PLS-00103: Encountered the symbol “(“ when expecting one of the followin的文章就介紹完了。如果您還想了解更多內(nèi)容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!