oracle创建用户及表空间

第一步:创建临时表空间

CREATE TEMPORARY TABLESPACE DB_TEMP

         TEMPFILE 'D:\oracle\product\10.2.0\oradata1\orcl\DB_TEMP.DBF'

         SIZE 32M

         AUTOEXTEND ON

         NEXT 32M MAxSIZE UNLIMITED

         EXTENT MANAGEMENT LOCAL;

第二步:创建数据表空间

CREATE TABLESPACE finance

         LOGGING

         DATAFILE 'D:\oracle\product\10.2.0\oradata1\orcl\finance.DBF'

         SIZE 32M

         AUTOEXTEND ON

         NEXT 32M MAXSIZE UNLIMITED

         EXTENT MANAGEMENT LOCAL;

 

第三步:创建用户

 CREATE USER finance IDENTIFIED BY finance

         ACCOUNT UNLOCK

         DEFAULT TABLESPACE finance

         TEMPORARY TABLESPACE DB_TEMP;

第四步:给用户授予权限


GRANT CONNECT,RESOURCE TO finance
GRANT DBA TO finance

posted @ 2015-03-14 13:04  java学习之旅  阅读(360)  评论(0编辑  收藏  举报