0
点赞
收藏
分享

微信扫一扫

oracle 删除表空间(tablespace)及数据文件的方法


– 创建表空间;
Create tablespace xihu
datafile ‘d:\oracleDB\xihu.dbf’
Size 100M
AutoExtend on
Next 10M
select tablespace_name from dba_tablespaces;
select tablespace_name from user_tablespaces;

select * from all_users;

oracle 删除表空间(tablespace)及文件的方法

一、drop user xxxx cascade;

二、drop tablespace xxxx including contents and datafiles

1.首先看一下是不是已经使用了OMF

sql>show parameter db_create

查看参数db_create_file_dest,如果已经设置

则:drop tablespace tablespacename 就可以直接删除表空间以及相应的数据文件

2.如果没使用OMF,则:

drop tablespace tablespacename including contents and datafiles


举报

相关推荐

0 条评论