How many arguments does proc_name() take?

You need to supply a separate placeholder for each argument to the
procedure.  If this section in the fine manual (perldoc DBI) is not clear,
please suggest alternate wording.
=====
Also, placeholders can only represent single scalar values.
For example, the following
statement won't work as expected for more than one value:

  "SELECT name, age FROM people WHERE name IN (?)"    # wrong
=====

There is also a problem between DBI 1.15 and DBD::Oracle 1.06 when returning
result sets, so if you are using DBI 1.15, drop back to 1.14.
--
Mac :})
** I normally forward private database questions to the DBI mail lists. **
Give a hobbit a fish and he'll eat fish for a day.
Give a hobbit a ring and he'll eat fish for an age.
----- Original Message -----
From: "Eric Riggers" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, May 10, 2001 16:29
Subject: passing an ORA_RSET into an Oracle stored procedure?


> I'm trying to call a stored procedure that needs a "record type
paramater".
> I'm unclear as to how to pass the record data.  The record data is a hash;
I
> believe i need to pass in just the values of the hash, as a flattened list
> $reg_string.
>
> Something like this?
>
> my $proc = 'proc_name';
> my $reg_string = 'John,Smith,,123 Main Street,,';
>
> my $sth = $dbh->prepare("BEGIN $proc(?,?); END;");
> $sth->bind_param(1, $reg_string, { ora_type => ORA_RSET } );
> $sth->bind_param_inout(2, \$self->{_result}, 100);
>
> Right now this throws the following error:
> Argument "ORA_RSET" isn't numeric in subroutine entry at
lib/Mail/Message.pm
> line 515.
> Can't bind :p1, ora_type 0 not supported by DBD::Oracle at
> lib/Mail/Message.pm line 515.


Reply via email to