Oracle7 Server Administrator's Guide

Contents Index Home Previous Next

Creating and Adding Datafiles to a Tablespace

You can create and add datafiles to a tablespace to increase the total amount of disk space allocated for the tablespace, and consequently the database.

To add datafiles to a tablespace, use either the Add Datafile dialog box of Server Manager/GUI, or the SQL command ALTER TABLESPACE. You must have the ALTER TABLESPACE system privilege to add datafiles to a tablespace.

The following statement creates a new datafile for the RB_SEGS tablespace:

ALTER TABLESPACE rb_segs
   ADD DATAFILE 'filename1' SIZE 1M;

If you add new datafiles to a tablespace and do not fully specify the filenames, Oracle7 creates the datafiles in the default directory of the database server. Unless you want to reuse existing files, make sure the new filenames do not conflict with other files; the old files that have been previously dropped will be overwritten.


Contents Index Home Previous Next