日期:2014-05-16  浏览次数:20342 次

创建表空间

1、创建表空间(创建一个表空间对应三个数据文件)

SQL>create tablespace ts_dong
logging
datafile '/opt/orcl_11g/oradata/dong/dong01.dbf'
size 200m
autoextend on
next 100m maxsize UNLIMITED ,
 '/opt/orcl_11g/oradata/dong/dong02.dbf'
size 200m 
autoextend on
next 100m maxsize UNLIMITED ,
 '/opt/orcl_11g/oradata/dong/dong03.dbf'
size 200m 
autoextend on
next 100m maxsize UNLIMITED 
extent management local;

2、追加表空间数据文件

?

SQL>alter database datafile '/opt/orcl_11g/oradata/dong/dong04.dbf' size 200m 
autoextend on
next 100m maxsize UNLIMITED  ;

3、查看所有表空间及对应数据文件

?

SQL>select file_name, tablespace_name from dba_data_files;
?

?