This article describes how to create user permissions in Oracle by creating a table. The following code is mainly used to compile the Oracle user creation permission, hoping to help you.
Note: Each language is executed separately and must end with a semicolon;
- // Create a space
- CreateTablespace test
- Datafile'C: \ oracle \ oradata \ orcl9 \ test. dbf' Size50 M
- DefaultStorage (initial 500 K
- Next500 K
- Minextents 1
- Maxextents unlimited
- Pctincrease 0 );
- // Create user permissions in Oracle
- // Create a user
- Create UserLxg identifiedByLxgDefaultTablespace test;
- // Authorization
- GrantResource,Connect, DbaToTest;
- // Delete the tablespace
- DropTablespace"Space name"Including contentsAndDatafiles
Delete a user
- drop user "lxg" cascade
Add tablespace
- alter tablespace chinawater add datafile 'c:\oracle\oradata\orcl9\ADDCHINAWATER.dbf' size 200M
Create user
- create user userName identified by password;
Create userName and password
2
Authorize a user
- GrantDbaToLxg;-- Grant DBA Permissions
- GrantUnlimited tablespaceToLxg;-- Grant unlimited tablespace
- Grant Select Any Table ToLxg;-- Grant query to any table
- Grant Select AnyDictionaryToLxg;-- Grant query to any dictionary
- grant dba to lxg;
- grant unlimited tablespace to lxg;
- grant select any table to lxg;
- grant select any dictionary to lxg;