Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Converting a string variable into a list of numeric values in PL/SQL

Converting a string variable into a list of numeric values in PL/SQL

From: GC <glchy_at_email.com>
Date: 5 Sep 2001 15:30:51 -0700
Message-ID: <be75cede.0109051430.462cb525@posting.google.com>


Hi,

im passing a variable (in PERL) containing a list of values to a PL/SQL stored procedure (SP). The SP is supposed to get that variable and 'decompose' it into a list of numeric values.

PERL



$list = "1,2,3";

PL/SQL



PROCEDURE upd_details(p_list varchar2) IS BEGIN
     update cm_details
     set wd_status = 'NEW'
     where wd_order not in (to_number(p_list));

END upd_details;

I have no problem calling & executing the SP from PERL. The problem is that the SP cannot convert "1,2,3" into numeric 1,2,3.

Can anyone suggest how to make a SP convert a string variable into a list of numeric values?

Thanks,

GC Received on Wed Sep 05 2001 - 17:30:51 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US