Creating and Using Temporary Table inside pl/sql function [message #2927] |
Thu, 22 August 2002 08:01 |
Lev Altman
Messages: 2 Registered: August 2002
|
Junior Member |
|
|
When I try to create temp table inside pl/sql function - CREATE GLOBAL TEMPORARY TABLE x_temp (y VARCHAR2(256) NOT NULL ) ON COMMIT DELETE ROWS; - oracle rejects it as DDL statement not alowed in pl/sql.
If I use EXECUTE IMMEDIATE 'CREATE GLOBAL TEMPORARY TABLE x_temp (y VARCHAR2(256) NOT NULL ) ON COMMIT DELETE ROWS' to create a temp table - the temp table name x_temp is not recognisable inside the function.
It must be an easy way to create a temporary table inside pl/sql and have its name recognizable.
|
|
|
|