ORACLE创建用户并指定默认表空和默认临时表空间

北京逸天教育 http://www.yitianjiaoyu.com

 

1. 创建临时表空间 

create temporary tablespace tianlihu_temp
tempfile 'D:/Oracle/oradata/TIANLIHU/tablespaces/tianlihu_temp.dbf' 
size 32m 
autoextend on 
next 32m maxsize 2048m
extent management local;

 

2. 创建数据表空间

create tablespace tianlihu
logging
datafile 'D:/Oracle/oradata/TIANLIHU/tablespaces/tianlihu.dbf' 
size 32m 
autoextend on 
next 32m maxsize 2048m
extent management local;

 

3. 创建用户并指定表空间

create user tianlihu identified by tianlihu
default tablespace tianlihu
temporary tablespace tianlihu_temp;

 4. 给用户授予权限

grant connect,resource,dba,sysdba to tianlihu;

 

你可能感兴趣的:(ORACLE创建用户并指定默认表空和默认临时表空间)