預存程序中遇到ORA-00942表或視圖不存在

來源:互聯網
上載者:User

預存程序中遇到ORA-00942表或視圖不存在

解決方案:

grant select, insert, update, delete on bookmarks.* to bm_user@localhost identified by 'password'

授權語句:意思是把表 XXX select, insert, update, delete許可權授給bm_user表

以sys身份登入,為system賦予select 和delete sys.fga_log$的許可權,否則下邊的預存程序添加會有問題。

Sql> grant select ,delete on sys.fga_log$ to system;

原因:

後來查資料得知如果使用者有dba角色,角色裡包含的許可權在預存程序裡不會被繼承;所以又單獨對tb_bil_acct_566 ,seq_bil_acct_his_hisid_566.nextval等作了顯式賦權,問題得以解決。

grant 授權的授權結果從哪裡看到?

grant select ,delete on sys.fga_log$ to system;--改的是哪個基表? --dba_tab_privs

select * from dba_tab_privs where grantee='SYSTEM' AND TABLE_NAME='FGA_LOG$'[@more@]grant select ,delete on sys.fga_log$ to system;--改的是哪個基表? --dba_tab_privs

select * from dba_tab_privs where grantee='SYSTEM' AND TABLE_NAME='FGA_LOG$

相關文章

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.