/*分為四步 */
/*第1步:創建臨時表空間 */
create temporary tablespace user_temp
tempfile 'D:\oracle\oradata\Oracle9i\user_temp.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;
/*第2步:創建數據表空間 */
create tablespace user_data
logging
datafile 'D:\oracle\oradata\Oracle9i\user_data.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;
/*第3步:創建用戶並指定表空間 */
create user username identified by password
default tablespace user_data
temporary tablespace user_temp;
/*第4步:給用戶授予權限 */
grant connect,resource,dba to username;
注:D:\oracle\oradata\Oracle9i為存放文件的路徑。
轉載自http://www.cnblogs.com/netsql/articles/1745978.html