Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to handle NULL collection (Type Table )

443808Sep 8 2005 — edited Sep 9 2005
Procedure ABC(p_in_tab_name IN tab_name)
IS
BEGIN
FOR l_count IN p_in_tab_name.FIRST..p_in_tab_name.LAST
LOOP
--process each records
END LOOP;
END ID;

here p_in_tab_name is Table Type of VARCHAR2 and can be NULL.

If I execute this procedure like:
ABC(p_in_tab_name => NULL);


I get exception - ORA-06531: Reference to uninitialized collection

Pls advice how should I can handle this case.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 7 2005
Added on Sep 8 2005
10 comments
2,672 views