title: PL/SQL where clause using IN() for an array
body: <p>Simple table:</p>
  
  <pre><code>CREATE TABLE Users (
    PersonID int,
    Name varchar(255),
    Salary int
  );
  </code></pre>
  
  <p>I have to write a cursor that will be used in a procedure. Cursor is supposed to return records whose Name field belongs to the array.</p>
  
  <pre><code>CREATE OR REPLACE TYPE namesArray AS TABLE OF int;
  /
  
  CURSOR luckyPeople(names IN namesArray) IS
  select PersonID from Users
  where Name IN(namesArray); //how this can be solved?
  </code></pre>
  
  <p>How can I use the array in the select clause?</p>
  
  <p>thanks</p>