清空 表空間

2021-08-31 20:31:44 字數 788 閱讀 5952

清空表空間:

drop tablespace sirm including contents

清空表空間並物理刪除檔案

drop tablespace sirm including contents and datafiles;

報錯:有域索引或次級物件

下列可以檢視 那些 影響了檔案刪除

檢視哪些objects儲存在example表空間,將其drop或者move,然後再drop tablespace

select owner,segment_name, segment_type from dba_segments where tablespace_name = 'example'; 

select distinct owner,segment_name, segment_type from dba_extents where tablespace_name='example';

2011-11-2 10:22:35

終於可以了

-- 先刪除使用者(如果要刪除的表空間上有多個使用者有相關資料,則要將多個使用者都刪除)

drop user user_name;

-- 再刪除表空間:

drop tablespace tablespace_name including contents and datafiles;

然後物理刪除表空間 就可以釋放空間了

清空Oracle臨時表空間

tags oracle 今天發現一oracle的sql語句執行超過了2分鐘,因為本人從事的專案資料量都不大,還沒遇到過2分鐘以上不出結果的時候。因此十分疑惑。執行了一段時間之後,發覺oracle無法連線出現異常。此時登入oracle安裝伺服器,sqlplus無法連線。檢視硬碟空間,發現硬碟已滿。經過...

清空oracle臨時表空間

清空臨時表空間 0.shutdown immediate 1.startup 啟動資料庫 2.create temporary tablespace temp2 tempfile home2 oracle oradata sysmon temp02.dbf size 512m reuse autoe...

oracle擴充套件表空間以及清空臨時表

查詢表空間大小 單位g select t.tablespace name,round sum bytes 1024 1024 1024 0 ts size from dba tablespaces t,dba data files d where t.tablespace name d.tables...