ORA-00942 when referencing a Global Temporary table
652920Aug 6 2008 — edited Aug 6 2008Newbie warning.
I've manually created global temporary table using a script similar to the following...
CREATE GLOBAL TEMPORARY TABLE gtt1
ON COMMIT PRESERVE ROWS
AS SELECT STUFF
FROM SOMEWHERE;
Then I'm trying to create a procedure which references the temporary table gtt1
CREATE OR REPLACE PROCEDURE "SCHEMAHERE"."PROCNAMEHERE"
(
PARMs_in )
AS
BEGIN
delete from gtt1;
select other stuff from gtt1;
END PROCNAMEHERE;
When I compile the sp I get:
ORA-00942: table or view does not exist
Please help!