//創(chuàng)建臨時表空間
create temporary tablespace test_temp
tempfile 'E:\oracle\product\10.2.0\oradata\testserver\test_temp01.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;
//創(chuàng)建數(shù)據(jù)表空間
create tablespace test_data
logging
datafile 'E:\oracle\product\10.2.0\oradata\testserver\test_data01.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;
//創(chuàng)建用戶并指定表空間
create user username identified by password
default tablespace test_data
temporary tablespace test_temp;
//給用戶授予權(quán)限
grant connect,resource to username;
//以后以該用戶登錄,創(chuàng)建的任何數(shù)據(jù)庫對象都屬于test_temp 和test_data表空間,這就不用在每創(chuàng)建一個對象給其指定表空間了。
轉(zhuǎn)載:http://virgos.javaeye.com/blog/337976
create temporary tablespace test_temp
tempfile 'E:\oracle\product\10.2.0\oradata\testserver\test_temp01.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;
//創(chuàng)建數(shù)據(jù)表空間
create tablespace test_data
logging
datafile 'E:\oracle\product\10.2.0\oradata\testserver\test_data01.dbf'
size 32m
autoextend on
next 32m maxsize 2048m
extent management local;
//創(chuàng)建用戶并指定表空間
create user username identified by password
default tablespace test_data
temporary tablespace test_temp;
//給用戶授予權(quán)限
grant connect,resource to username;
//以后以該用戶登錄,創(chuàng)建的任何數(shù)據(jù)庫對象都屬于test_temp 和test_data表空間,這就不用在每創(chuàng)建一個對象給其指定表空間了。
轉(zhuǎn)載:http://virgos.javaeye.com/blog/337976