title: ORACLE PL/SQL: Dynamic SQL Select using a Collection
body: <p>Is it possible to create a dynamic SQL statement that pulls from an existing collection?</p>
  
  <pre><code>l_collection := pack.get_items(
                  i_code =&gt; get_items_list.i_code ,
                  i_name =&gt; get_items_list.i_name );
  </code></pre>
  
  <p>Now, let's say I want to select a COUNT from that collection using dynamic SQL. Is that possible? Furthermore, I want to do a sub select from that collection as well.</p>