ORA-12986錯誤解決

來源:互聯網
上載者:User

今天在刪除一個大表的列,意外被DBA重啟DB後,再執行查詢時,就報了ORA-12986這個錯誤,先來一起瞭解下這個錯誤:

ORA-12986: columns in partially dropped state. Submit ALTER TABLE DROP COLUMNS CONTINUE

Cause: An attempt was made to access a table with columns in partially dropped state (i.e., drop column operation was interrupted).

Action: Submit ALTER TABLE DROP COLUMNS CONTINUE to complete the drop column operation before accessing the table.

可以看到導致這個錯誤的原因是因為你正在刪除列,但是刪除到一半時,進程被意外終止了,導致表處在部分刪除狀態,所以報了咋麼個錯誤,你要做的就是繼續刪除,看下下面的例子:

1.將列置為unused

ALTER TABLE test1 SET UNUSED COLUMN Tablespace_name;

2.刪除unused列

ALTER TABLE test1 DROP UNUSED COLUMN CHECKPOINT 5;

在未執行完畢前,用 shutdown abort強制關閉資料庫(如果用shutdown immediate就看不到效果,它會等到執行完畢才會關閉資料庫)

3.重新啟動資料庫,查看test1表,報錯

4.繼續刪除未刪完的列

ALTER TABLE test1 DROP COLUMNS continue

5.執行完畢後重新查詢test1表,就OK了

ORA-01172、ORA-01151錯誤處理

ORA-00600 [2662]錯誤解決

ORA-01078 和 LRM-00109 報錯解決方案

ORA-00471 處理方法筆記

ORA-00314,redolog 損壞,或丟失處理方法

ORA-00257 歸檔日誌過大導致無法儲存的解決辦法

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.