一周沒用過oracle,打開數據庫的時候報錯:
執行請求的操作時遇到錯誤:
ORA-01219: 數據庫或可插入數據庫未打開: 僅允許在固定表或視圖中查詢
01219. 00000 - "database or pluggable database not open: queries allowed on fixed tables or views only"
*Cause: A query was issued against an object not recognized as a fixed
table or fixed view before the database or pluggable database has
been opened.
*Action: Re-phrase the query to include only fixed objects, or open the
database or pluggable database.
供應商代碼 1219
解決:
1、重啟電腦,不管用;
2、連接上sys后,執行下面語句:
select open_mode from v$database; alter database open; select con_id,dbid,NAME,OPEN_MODE from v$pdbs;
3、上面語句執行后基本正常,然后切換容器:
alter pluggable database orclpdb open;
alter session set container=orclpdb;