Oracle表空间和用户创建

来自ling
跳转至: 导航搜索
CREATE SMALLFILE TABLESPACE "CHNL_DATA" 
DATAFILE 'D:\oracle\product\10.2.0\oradata\orcl\CHNL_DATA_data.dbf'
SIZE 100M AUTOEXTEND ON NEXT 2048K MAXSIZE UNLIMITED 
LOGGING EXTENT MANAGEMENT LOCAL SEGMENT SPACE MANAGEMENT AUTO;

CREATE SMALLFILE TABLESPACE "CHNL_INDEX" 
DATAFILE 'D:\oracle\product\10.2.0\oradata\orcl\CHNL_INDEX.dbf'
SIZE 100M AUTOEXTEND ON NEXT 2048K MAXSIZE UNLIMITED 
LOGGING EXTENT MANAGEMENT LOCAL SEGMENT SPACE MANAGEMENT AUTO;


CREATE SMALLFILE TABLESPACE "CHNL_TEMP" 
DATAFILE 'D:\oracle\product\10.2.0\oradata\orcl\CHNL_TEMP.dbf'
SIZE 100M AUTOEXTEND ON NEXT 2048K MAXSIZE UNLIMITED 
LOGGING EXTENT MANAGEMENT LOCAL SEGMENT SPACE MANAGEMENT AUTO;


create user CHANNEL
  identified by "CHANNEL"
  quota unlimited on CHNL_DATA
  quota unlimited on CHNL_INDEX;
-- Grant/Revoke role privileges 
grant connect to CHANNEL;
grant resource to CHANNEL;
grant dba to CHANNEL;