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

Home -> Community -> Usenet -> c.d.o.server -> Re: Help Please

Re: Help Please

From: Thomas Kyte <tkyte_at_us.oracle.com>
Date: Sat, 21 Jul 2001 21:31:28 GMT
Message-ID: <9i5jkh0c10@drn.newsguy.com>

In article <Cdr17.18713$Kl3.1271186_at_news1.cableinet.net>, "Baba says...
>
>I would like to pass a literal to a procedure in a package.
>
>i.e EXECUTE package.procedure (' ''X1'', ''X2'', '' X3'' ')
>
>inside the procedure, I have a cursor which states:-
>select field_1, field_2
>from table
>where field_2 IN (argument_passed_to_the_procedure)
>
>Is it possible to pass a sting here?
>
>Anyhelp please
>
>

See
http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:146012348066 for the approach.

In 8i, the syntax is easier, instead of

ops$tkyte_at_8> select *
  2 from THE ( select cast( in_list('1,2,3,5,12') as

            mytableType ) from dual ) a
  3 /

it's just:

ops$tkyte_at_8i> select *
  2 from TABLE ( cast( in_list('1,2,3,5,12') as mytableType ) )   3 /

in the examples there.

--
Thomas Kyte (tkyte@us.oracle.com)             http://asktom.oracle.com/ 
Expert one on one Oracle, programming techniques and solutions for Oracle.
http://www.amazon.com/exec/obidos/ASIN/1861004826/  
Opinions are mine and do not necessarily reflect those of Oracle Corp 
Received on Sat Jul 21 2001 - 16:31:28 CDT

Original text of this message

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