5 pts.
 DDL in PL/SQL procedure
I have a question, i create drop and create a table in pl/sql proc using execute immediate. Later I declare a ref cursor, to process data from table created. Problem is the procedure executes correctly, but after execution procedure becomes invalid. How can i solve this issue. Thanks in advance.

Software/Hardware used:
ASKED: March 11, 2009  7:13 AM
UPDATED: March 11, 2009  10:32 PM

Answer Wiki:
The procedure becomes invalid because it references the table you drop and re-create. I think you will need to change your procedure to use dynamic sql for all operations related to the table you drop. ------------------- You can use temp tables instead creating and dropping tables in your database. Even better depending on the amount of data you can use table variables. You can find information on both in Books On Line or search google. -Koverton44
Last Wiki Answer Submitted:  March 11, 2009  10:32 pm  by  carlosdl   63,535 pts.
All Answer Wiki Contributors:  carlosdl   63,535 pts. , Koverton44   150 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _