--创建数据表空间
create tablespace spaceName2
datafile 'd:\oracle\product\10.2.0\oradata\orcl\AMS.dbf'size 2000M
autoextend onnext 100M maxsize unlimited logging
extent management local autoallocate
segment space management auto;
--创建用户并指定表空间
createuser dms
identified by dms
default tablespace DMS
temporary tablespace TEMP;
-- Grant/Revoke role privileges
grantconnectto dms with admin option;
grant dba to dms with admin option;
grant resource to dms with admin option;
grant unlimited tablespace to dms with admin option;
--删除表空间以及数据文件
drop tablespace spaceName including contents and datafiles;
--删除用户名
dropuser username cascade;