Why dose a user granted dba role do not has select any table privilege in procedure? [message #41203] |
Tue, 10 December 2002 01:52  |
zhangjin
Messages: 3 Registered: December 2002
|
Junior Member |
|
|
Why a user granted dba role can't select any table in procedure?
I create a user xy and grant dba to it.
There is table named zj_test in the schama unitele ,when i connect as xy by sqlplus,i can see the table unitele.zj_test
but,when i create a procedure ,it seemed that the procedure can't find the table unitele.zj_test;
after i grant select any table to xy,the procedure complied well;
but why ? Does the role dba can't work well in procedure?
SQL> create user xy identified by xy;
SQL> grant dba to test;
SQL> connect xy/xy;
Connected.
SQL> insert into unitele.zj_test values ('adsfas');
1 row created.
SQL> commit;
Commit complete.
SQL> select * from unitele.zj_test;
A
--------------------------------------------------------------------------------
adsfas
SQL> create or replace procedure zj_test_p1
2 as
3 begin
4 insert into unitele.zj_test values ('asdfa');
5 commit;
6 end;
7 /
Warning: Procedure created with compilation errors.
SQL> show errors
Errors for PROCEDURE ZJ_TEST_P1:
LINE/COL ERROR
-------- -----------------------------------------------------------------
4/1 PLS-00201: identifier 'ZJ_TEST' must be declared
4/1 PL/SQL: SQL Statement ignored
|
|
|
|