表空间创建
create tablespace stbss datafile '/opt/app/oracle/product/11.2.0/db_1/db01.dbf' size 100m;
mytablespace : 表空间名称
datafile: 指定表空间对应的数据文件(位置)
size:表空间的初始大小
autoextend on :自动增长,
next: 一次自动增长的大小
格式:
1.impdp & expdp的用法:
impdp 用户名/密码@服务名 导入已经有的数据库
impdp system/123@orcl
expdp 用户名/密码@服务名 导出已经有的数据库,默认(app\Administrator\admin\orcl\dpdump)
expdp ysgl/abc123@ysgl version=’11.2.0.1.0’
创建唯一索引:
create unique index index_01 on test(a,b);
普通索引:
create index index_02 on test(a);