Thursday, January 12, 2012

TABLESPACES

A tablespace can contain many tables, indexes, and so forth. It has a size that is
initially assigned by the DBA. As data is inserted and updated, the amount of free
space in the tablespace diminishes. As the space used reaches 100%, the DBA
may choose to archive rows or expand the tablespace by extending one or more
existing datafiles or by adding a new datafile to the tablespace

CREATE A TABLESPACE
You create a new tablespace with the CREATE TABLESPACE command, which has
the following syntax:
CREATE TABLESPACE <tablespace_name>
DATAFILE <datafile_name> SIZE <size_of_datafile>
DEFAULT STORAGE
(INITIAL <size_of_initial_extent>
NEXT <size_of_next_extent>
MINEXTENTS <minimum_number_of_extents>
MAXEXTENTS <maximum_number_of_extents>
PCTINCREASE <extent_growth_rate>
)
PERMANENT;

DELETE A TABLESPACE

DROP TABLESPACE <tablespace_name>;


No comments:

Post a Comment