Hello,

I'm having an issue with getting a sys_refcursor back from a function.

Particulars:
PERL version: 5.8.3
Oracle Client: 10.2.0.4  32 bit (using lib32)
DBI version 1.41

The function returns a sys_refcursor.

$sth = $dbh->prepare(q{begin :csr := my_function('12345','','');
end;});

my $sth2;
$sth->bind_param_inout(":csr", \$sth2, 0, { ora_type => ORA_RSET } );

$sth->execute();

$sth->finish;
$dbh->disconnect;


It fails and produces the following output:


Field 9 has an Oracle type (108) which is not explicitly supported
at ./test4_ora.pl line 23.
Field 18 has an Oracle type (108) which is not explicitly supported
at ./test4_ora.pl line 23.
Field 19 has an Oracle type (108) which is not explicitly supported
at ./test4_ora.pl line 23.
Field 20 has an Oracle type (108) which is not explicitly supported
at ./test4_ora.pl line 23.
DBD::Oracle::st execute failed: ERROR OCIDefineObject call needed but
not implemented yet [for Statement "declare csr sys_refcursor;
begin :csr := my_function('12345','',''); end;" with
ParamValues: :csr=DBI::st=HASH(0x33180c)] at ./test4_ora.pl line 23.


However I can execute the function if I don't use the
bind_param_inout:

$sth = $dbh->prepare(q{declare csr sys_refcursor; begin csr :=
my_function('12345','',''); end;});
$sth->execute();

and it does not give me any errors.

I've tried:

$sth = $dbh->prepare(q{declare csr sys_refcursor; begin csr :=
my_function('12345','',''); csr2 := csr; end;});

my $sth2;
$sth->bind_param_inout(":csr2", \$sth2, 0, { ora_type => ORA_RSET } );

and it gives me the same Oracle type (108) errors.

Is there an issue with the DBI version I'm using along with my Oracle
client or  am I not doing something right?

I appreciate your help.

Phil


Reply via email to