oracle新建用户和表空间

使用SYSTEM或...登陆

--建立数据库用户

create user 用户名 identified by 密码

default tablespace 表空间名

temporary tablespace temp

quota 0 on system

quota unlimited on 表空间名;

Grant CONNECT,RESOURCE,dba TO 用户名;

查询数据库的表空间名:

select tablespace_name from dba_tablespaces;

-- 赋予权限

grant connect to 用户名 with admin option;

-- 角色

grant DBA to 用户名 with admin option;