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 -> PL-SQL Procedure Parameter used with IN.

PL-SQL Procedure Parameter used with IN.

From: Darren M Lines <darren.lines_at_futuremedia.co.uk>
Date: Thu, 06 May 1999 19:38:30 +0100
Message-ID: <3731E1A5.DE1BDA8C@futuremedia.co.uk>


Hi All,

Hope somebody can help me with this.

If I have a VARCHAR parameter that contains a comma seperated list, can I use that with the select IN?

E.g.

procedure testIn(p_aString VARCHAR2) IS

  l_cnt NUMBER;

  begin

    select count(*)

      into l_cnt
      from TestTable
     where field1 in (p_aString);

end testIn;

execute testIn('''1'',''2''');

This approach dosn't seem to work. Any ideas greatly appreciated.

Many thanks,

Colin Smith. Received on Thu May 06 1999 - 13:38:30 CDT

Original text of this message

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