Sumitra Gatade wrote:
> Hi,
>
> I am trying to execute the stored procedure using dbh. The procedure
> details are as follows:
> proc_dequeue( BALID,strRequestXML,strStatus)
>
> where:
> BALID - Integer,
> strRequestXML - XMLType,
> strStatus - varchar
>
> The perl script implemented is :
>
> my $sth = $dbh1->prepare("begin
> proc_dequeue(:BALID,:strRequestXML,:strStatus); end;");
>
> $sth->bind_param_inout(":BALID",\$o_balid,20,\%attr );
> $sth->bind_param_inout(":strRequestXML",\$o_requestXML,50000,\%attr);
> $sth->bind_param_inout(":strStatus",\$o_status,2,\%attr);
>
> and the error message i am getting is :
>
> DBD::Oracle::st execute failed: ORA-06550: line 1, column 7:
> PLS-00306: wrong number or types of arguments in call to
> 'proc_dequeue'
You are passing a string to a function that expects XMLType, an opaque
Oracle object type. The XMLType API provides a constructor that takes a
varchar2 argument, so try changing your statement to:
begin proc_dequeue(:BALID,XMLType(:strRequestXML),:strStatus); end;
Regards,
Philip