1.创建用户并设置默认表空间

create tablespace tablespacename datafile 'tablespacename.dbf' size 200m autoextend on next 10m maxsize unlimited;(oracle默认位置)

create tablespace tablespacename datafile 'D:\orcletablespace\tablespacename.dbf' size 200m autoextend on next 10m maxsize unlimited;
create temporary tablespace temptablespacename tempfile 'D:\orcletablespace\temptablespacename.dbf' size 200m autoextend on next 32m maxsize 2048m extent management local;
create user username  identified by password default tablespace tablespacename temporary tablespace temptablespacename;

grant connect,resource,dba to username;

附:

--删除数据库用户
drop user test cascade;

--查询用户对应的表空间及临时表空间
select t.username,t.default_tablespace, t.temporary_tablespace from dba_users t ;

--查询表空间及其对应的物理路径
select tablespace_name, file_id,file_name, round(bytes/(1024*1024),0) total_space from dba_data_files order by tablespace_name;

--给原表空间扩展物理文件
alter tablespace TEST add datafile '/oracle/data/dbf/TEST_EXTEND.dbf' size 1000m autoextend on next 200m maxsize 4000m;
alter tablespace TEST add datafile '/oracle/data/dbf/TEST_EXTEND.dbf' size 1000m autoextend on next 200m maxsize unlimited;

--查询oracle中directory路径

select * from dba_directories;

最新文章

  1. jetty项目中静态文件不能修改问题
  2. 64位CentOS源码编译方式安装wine
  3. POJ 3320 尺取法,Hash,map标记
  4. 常用IT类英文词汇 - 1
  5. gulp-uglify《JS压缩》----gulp系列(四)
  6. 将 jsp 页面的值 传到struts2 action中(不是表单中的值)
  7. Redis + Jedis + Spring整合遇到的异常(转)
  8. js中document.write()使用方法
  9. BZOJ 3208: 花神的秒题计划Ⅰ
  10. spring +springmvc+mybatis组合总结
  11. attr与prop html与text
  12. bzoj4767两双手 容斥+组合
  13. 【详记MySql问题大全集】三、安装之后没有my.ini配置文件怎么办
  14. java中的排序--排序容器_TreeSet与TreeMap
  15. spring各个版本源码
  16. Red Hat7.2 上安装 MySQL5.5.58
  17. [转载]显示SVN控制台
  18. PostgreSQL索引介绍
  19. 常用模块之 shutil,json,pickle,shelve,xml,configparser
  20. 1003. [ZJOI2006]物流运输【区间DP+最短路】

热门文章

  1. IIS7 UNC File caching issue
  2. 自定义指令 格式化input数据为非负整数
  3. pytest.3.Assert
  4. Dubbo的原理以及详细原理、配置
  5. 打开word文档总是自动弹出控件工具条的解决办法:
  6. windows2008系统缓存修改
  7. 把1,2,3…n*n 的数字按照顺时针螺旋的形式填入数字矩阵
  8. vue之v-model
  9. 在docker宿主机上查找指定容器内运行的所有进程的PID
  10. npm 淘宝镜像