1. Create a table space
For example:
(1) The table space is named Myplace;
(2) Data file path is E:\oracle\oracle_home\oradata\myspace
(3) file name is MYDBF.DBF, space size is 32M
(4) Set table space Auto-expansion, 32M each time, the maximum space is 2048M
(5) Local Management table space
Create Tablespace MySpace
Logging
DataFile ' E:\oracle\oracle_home\oradata\myspace\mydbf.dbf '
Size 32m
Autoextend on
Next 32m MaxSize 2048m
Extent management Local;
2. Create a temporary table space
For example, the temporary tablespace name is Temp_myspace
Create temporary tablespace temp_myspace
Tempfile ' E:\oracle\oracle_home\oradata\myspace\temp_mydbf.dbf '
Size 32m
Autoextend on
Next 32m MaxSize 2048m
Extent management Local;
3. Create a user and specify tablespace and temp table space
For example:
(1). The user name is username
(2). Password is password
(3). Specify Tablespace for MySpace
(4). Temporary tablespace is Temp_myspace
Create user username identified by password
Default Tablespace MySpace
Temporary tablespace temp_myspace;
Note: If you do not specify a temporary tablespace, the temporary table space for the system will be used by default temp
View current Temporary tablespace: SELECT * from database_properties where property_name = ' default_temp_tablespace ';
4. Authorization to the user
(1). Connection permissions--most basic permissions (login)
(2). Developer's privileges (e.g., build table, Index)
Grant Connect, resource to username;
5. View User Permissions
SELECT * from Dba_role_privs;