Oracle creates databases, tablespaces, users, and authorizes
You can use the default database ORCL after installing Oracle database software, or you can create a custom database as needed. Table spaces are used to categorize resources in a database, each user has a default tablespace, or you can specify a default tablespace for the user.
1. Create a database
The simple way to do this is to use the ' DB Configuration Assistant ' database Configuration tool to create from the wizard
2. Create a table space
You need to create custom table spaces and temporary tablespaces in real-world use
2.1. Create a table space
Create Tablespace Tabspace_name
Logging
DataFile ' E:\app\oratable_space\ tabspace_name_temp.dbf '
Size 50m
Autoextend on
Next 50m maxsize 20480m
Extent management Local;
Where Tabspace_name is the table space name, ' E:\app\oratable_space\ tabspace_name_temp.dbf ' is the full path file name of the tablespace, and other parameters can be changed as needed
2.2, create temporary table space
Create temporary tablespace tabspace_name_temp
Tempfile ' E:\app\table_space\ tabspace_name_temp.dbf '
Size 50m
Autoextend on
Next 50m maxsize 20480m
Extent management Local;
Where tabspace_name_temp is the temporary table space name, ' E:\APP\ORATABLE_SPACE\TABSPACE_NAME_TEMP.DBF ' is the full path file name of the temporary tablespace, and other parameters can be changed as needed
3. Create user
You need to create users, specify tablespaces and temporary tablespaces, and authorize users in real-world use
3.1. Create user
Create user user_name identified by User_password
Default Tablespace tabspace_name
Temporary tablespace tabspace_name_temp;
3.2, to the user authorization
Grant CONNECT,RESOURCE,DBA to user_name;