The following two statements create a temporary tablespace with a 64 KB extent size, and then a new temporary table in that tablespace.
CREATE TEMPORARY TABLESPACE tbs_t1
TEMPFILE 'tbs_t1.f' SIZE 50m REUSE AUTOEXTEND ON
MAXSIZE UNLIMITED
EXTENT MANAGEMENT LOCAL UNIFORM SIZE 64K;
CREATE GLOBAL TEMPORARY TABLE admin_work_area
(startdate DATE,
enddate DATE,
class CHAR(20))
ON COMMIT DELETE ROWS
TABLESPACE tbs_t1;
By default, rows in a temporary table are stored in the default temporary tablespace of the user who creates it.
However, you can assign a temporary table to another tablespace upon creation of the temporary table by using the
TABLESPACE
clause of CREATE GLOBAL TEMPORARY TABLE
.
Comments