Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: How to Create Local Temporary Table
In Oracle
A temporary table structure is visible to all session.
Data is visible only to that particular session.
you can have it either session specific or transaction specific.
SQL> CREATE GLOBAL TEMPORARY TABLE mytemp (a number, b number) on commit delete rows; 2
Table created.
SQL> insert into mytemp values(1,1);
1 row created.
SQL> select * from mytemp;
A B
---------- ----------
1 1
NOTE - This record will not be visible in other sessions.
SQL> commit;
Commit complete.
SQL> select * from mytemp;
no rows selected
you can give
on commit delete rows or preserve rows.
Received on Thu Apr 20 2006 - 01:24:39 CDT