Re: Using vaarray in dynamic sql - ORA-00904: invalid identifier

From: Kevin S <>
Date: Tue, 27 Jan 2009 07:08:46 -0800 (PST)
Message-ID: <>

5 minutes after posting this I foud a solution.

  PROCEDURE testmemberofprc(

            po_ref_cursor OUT RefCursor)   IS
    --TYPE alc_tab IS TABLE OF aggregatelevelright.aggregatelevelcode %TYPE INDEX BY PLS_INTEGER;
    ntt type_varchar2_4000;

    v_sql VARCHAR2(2000);
    v_errcode VARCHAR2(2000);

  BEGIN     ntt := type_varchar2_4000('A', 'B', 'C');

    v_sql := 'SELECT ks_varchar2 ' ||

'FROM ks ' ||
'WHERE ks_varchar2 MEMBER OF :ntt ';
OPEN po_ref_Cursor FOR v_sql USING ntt;


       v_errcode := Sqlerrm;

  END testmemberofprc; Received on Tue Jan 27 2009 - 09:08:46 CST

Original text of this message