In DCL(Data control language) we have,
SQL> grant select on emp to system;
Grant succeeded.
SQL> conn system/admin
Connected.
SQL> select * from kkm.emp;
ID NAME SALARY
---------- --------------- ----------
1 mohan 1500
3 suresh 7700
4 sohan 1900
7 sujit 2200
Revoke: To take back the access on a table from another schema we use revoke.
SQL> revoke select on emp from system;
Revoke succeeded.
- grant
- revoke
SQL> grant select on emp to system;
Grant succeeded.
SQL> conn system/admin
Connected.
SQL> select * from kkm.emp;
ID NAME SALARY
---------- --------------- ----------
1 mohan 1500
3 suresh 7700
4 sohan 1900
7 sujit 2200
Revoke: To take back the access on a table from another schema we use revoke.
SQL> revoke select on emp from system;
Revoke succeeded.
0 comments:
Post a Comment