Tablespace and Temporary Tablespace
Tablespace and Temporary Tablespace
Types of tablespace:
In Oracle Database, there are several types of tablespaces, each
designed for specific purposes. Here are the common types of
tablespaces:
1. Permanent Tablespace:
Permanent tablespaces are the most common type and
are used to store permanent data, such as tables and
indexes, that persist across database sessions.
They typically contain user-created objects that are
intended to be long-lasting and are not temporary in
nature.
Permanent tablespaces are often used for storing
application data and system objects that are essential
for the functioning of the database.
2. Temporary Tablespace:
Temporary tablespaces are used for temporary storage
of data during database operations such as sorting,
joining, and aggregating.
They are used to store intermediate result sets
generated during SQL query processing.
Temporary tablespaces are often used to support
operations that require large amounts of temporary
storage, such as sorting large result sets or performing
complex data manipulations.
3. Undo Tablespace:
Undo tablespaces are used to store undo data, which is
used to roll back transactions and provide read
consistency.
When a transaction modifies data in the database, the
original data values are stored in the undo tablespace
before the changes are committed.
Undo tablespaces are essential for maintaining the
integrity of transactions and supporting features such
as rollback and read consistency.
4. System Tablespace:
The system tablespace is a special type of tablespace
that contains the data dictionary, which stores
metadata about the database objects and their
relationships.
It also contains the SYSTEM and SYSAUX tablespaces,
which contain system-related objects and auxiliary
objects used by the database.
The system tablespace is critical for the functioning of
the database and should be managed carefully to
ensure database stability and performance.
5. Bigfile Tablespace:
Bigfile tablespaces are a special type of tablespace
introduced in Oracle Database 11g that allows for the
creation of very large data files, up to 4 exabytes in
size.
Unlike traditional tablespaces, which consist of multiple
smaller data files, a bigfile tablespace consists of a
single large data file.
Bigfile tablespaces are often used for storing large
tables, indexes, or other objects that require large
amounts of storage space.
6. Temporary Undo Tablespace:
Temporary undo tablespaces are a variation of undo
tablespaces that are used specifically for temporary
undo data storage.
They are typically used in situations where temporary
undo storage is needed, such as during online table
redefinition operations or in certain types of partition
maintenance operations.
Temporary Tablespace
1) To see the structure of the table dba_temp_files;
To on autoexnted datafile;