--1.创建表空间GWAMRTHB_tablespace
create tablespace GWAMRTHB_tablespace
datafile 'E:\GWAMRTHB\DB_Data\orcl\GWAMRTHB.dbf' size 100M
AUTOEXTEND ON NEXT 20M
extent management local autoallocate
-- 2.创建临时表空间GWAMRTHB_temptablespace
create temporary tablespace GWAMRTHB_temptablespace
tempfile 'E:\GWAMRTHB\DB_Data\orcl\GWAMRTHB_temp.dbf'
size 50m
autoextend on
next 10m maxsize 20480m
extent management local;
-- 3.创建用户并分配表空间
create user GWAM identified by Abc12345
default tablespace GWAMRTHB_tablespace
temporary tablespace GWAMRTHB_temptablespace
-- 4.给用户分配权限
grant connect,resource,dba to GWAM
转载于:https://my.oschina.net/qihaitao/blog/395108