Oracle permission command favorites
Default User and password in Oracle9i:
Sys/change_on_install [as sysdba],
System/Manager
Scott/Tiger
1. permission management
DBA login Conn/As sysdba
Create user myusername identified by mypassword
Grant create session to myusername
Grant create table to myusername
Authorize tablespace grant unlimited/default/template tablespace to myusername
Revoke User Permissions revoke create table from myusername
View the system permission of the current user select * From user_sys_privs
2. Object Permissions
Grant select on TB to myusername
Grant insert on TB to myusername
Grant all permissions on TB to myusername
Revoke all permissions revoke all on TB to myusername
Grant permissions to all grant create any table to public
Grant column permission Update (name) on TB to myusername
View the permissions of the current user object select * From user_tb_privs
View the select * From user_col_privs permission of the authorized user Column
3. Transfer Permissions
Grant alter ant table to myusername
Grant alter any table to myusername with admin Option
Grant alter any table to myusername with grant option
4. Role (Set of permissions)
Create role myrole
Grant create table to myrole permissions to a role
Grant create session to myrole
...........................
Grant the role to the user grant myrole to myusername
Delete role drop role myrole
5. Three login verification mechanisms
· Operating System verification
· Password File Verification
· Database Verification
Alter user myusername identified by bbb
User locks alter user myusername account lock
Unlock alter user myusername account unlock
User password expired immediately alter user myusername password expire
Administrator Password loss orapwd file = C:/Oracle/ora92/database/pwdora9i. ora Password = KKK entries = 10
Delete a user and cascade all resources of the User: Drop user myusername cascade;
[Start the Oracle listener and start the Oracle instance]