title: Collection type as a cursor parameter
body: <p>I need to do a cursor that receives a list as a parameter. I've tried this:</p>
  
  <pre><code>declare
  
  type array_t is table of varchar(50); -- //also tried varray(10) instead of table
  
  cursor c_cursor (p_list array_t) is
  select 
      field_1
  from 
      table_1
  where 
      field_2 in p_list;
  
  a_list array_t;
  
  begin
      a_list := array_t('aaa',
          'bbb',
          'cccc',
          'ddd');
  
      for v_cursor in c_cursor(a_list) loop
          dbms_output.put_line(v_cursor.field_1);
      end loop;
  end;
  </code></pre>
  
  <p>and I get the following error</p>
  
  <pre><code>ORA-06550: line 11, column 21:
  PLS-00642: local collection types not allowed in SQL statements
  </code></pre>
  
  <p>I have read about using the <code>CREATE OR REPLACE</code> method but I cannot use <code>CREATE OR REPLACE</code> in this case (actually the database is read-only).</p>
  
  <p>Is there any possible solution?</p>