【问题标题】:PLS-00306: wrong number or types of arguments in call to [closed]PLS-00306:调用 [关闭] 时参数的数量或类型错误
【发布时间】:2009-04-23 16:18:35
【问题描述】:

谁能帮我解决这个错误。当我尝试第一个程序时它可以工作,但当我输入两个数字时它不能工作。有什么想法吗?

create or replace package LE2_P1
is
procedure GENERATE_MULTIPLICATION_TABLE(p_axis_both in number);
procedure GENERATE_MUTLIPLICATION_TABLE(p_axis_x in number, p_axis_y in number);
end LE2_P1;
/

create or replace package body LE2_P1
as
procedure GENERATE_MULTIPLICATION_TABLE(p_axis_both in number)
is
bb number := 1;
eb number := p_axis_both;
begin
for xyz in 1 .. eb loop
for xyx in 1 .. eb loop
dbms_output.put(CHR(9) || to_char(xyz * (bb + xyx - 1)));
end loop;
dbms_output.put_line(CHR(13) || CHR(10));
end loop;
end GENERATE_MULTIPLICATION_TABLE;
procedure GENERATE_MUTLIPLICATION_TABLE(p_axis_x in number, p_axis_y in number)
is
bb number := p_axis_x;
eb number:= p_axis_y;
begin
for xyz in 1 .. eb loop
for xyx in 1 .. eb loop
dbms_output.put(CHR(9) || to_char(xyz * (bb + xyx - 1)));
end loop;
dbms_output.put_line(CHR(13) || CHR(10));
end loop;
end GENERATE_MUTLIPLICATION_TABLE;

end LE2_P1;
/

declare
x number := 5;
y number := 3;
begin
LE2_P1.GENERATE_MULTIPLICATION_TABLE(x,y);
end;
/

【问题讨论】:

    标签: sql stored-procedures plsql


    【解决方案1】:

    带有两个参数名称的过程输入错误:MU T L IPLICATION

    【讨论】:

      【解决方案2】:

      OracleParameter[] pr=新 OracleParameter[20]; pr[1]=new OracleParameter("IN_BILL_COMPCD_C",OracleType.VarChar); pr[1].Value=IN_BILL_COMPCD_C; pr[1]=new OracleParameter("IN_BILL_BRCD_C",OracleType.VarChar); pr[1].Value=IN_BILL_BRCD_C;

      两个参数传入单个值。这就是为什么会出现这个错误。

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 2010-09-07
        • 1970-01-01
        • 2018-03-22
        • 2014-10-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多