[英]the table/view doesn't exist by using different schema
1)在模式A下創建一個表。
create table test_PK (
stdid INT NOT NULL,
stdname VARCHAR(10),
PRIMARY KEY(stdid)
);
insert into test_pk values (10,'Bob'); //Here works fine
2)執行:
GRANT SELECT,INSERT,DELETE ON TEST_PK TO B; //works fine
3)要使用模式B登錄數據庫,請在執行select * from test_pk;
時執行select * from test_pk;
它抱怨:
ORA-00942:表或視圖不存在
00942. 00000-“表或視圖不存在”
*原因:
*行動:
錯誤在行:12列:14
我錯過了什么?
我的猜測是,使用其他用戶登錄時需要指定架構:
select * from A.test_pk
這篇文章也可能會有所幫助: ORA-00942:可以從“ schema.table”中選擇,但不能從“ table”中選擇嗎? -您可以創建一個同義詞來繞過必須在SELECT中指定架構的情況。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.