Oracle 11g export and import
2016-05-12 14:04
567 查看
a. Export:
sqlplus:
1. conn system/pass@xe as sysdba
2. create directory dump as 'c:\dump';
3. grant read,write on directory dump to public;
cmd:
expdp system/pass@xe schemas=trunk dumpfile=trunk.dmp directory=dumplogfile=trunk.log;
b. Import:
sqlplus:
1. connsystem/pass@xe as sysdba
2. createdirectory dump as 'c:\dump';
3. grantread,write on directory dump to public;
4. createtemporary tablespace tem_space tempfile 'D:\dump\xe\tem_space.dbf' size50m autoextend on next 50m maxsize 20480m extent management local;
5. createtablespace sungard datafile 'c:\dump\xe\sungard.dbf' size 50M autoextend onnext 50M maxsize 20480M;
6. create user trunk identified by pass default tablespace sungard temporary tablespacetem_space;
7. grantconnect,resource,dba to trunk;
cmd:
impdpsystem/pass directory=dump dumpfile=nxg_it.dmp REMAP_SCHEMA=nxg_it:trunkfull=y;
ps: REMAP_SCHEMA = [dump文件对应的user]:[自己数据库新建的user], 同理 REMAP_TABLESPACE
sqlplus:
1. conn system/pass@xe as sysdba
2. create directory dump as 'c:\dump';
3. grant read,write on directory dump to public;
cmd:
expdp system/pass@xe schemas=trunk dumpfile=trunk.dmp directory=dumplogfile=trunk.log;
b. Import:
sqlplus:
1. connsystem/pass@xe as sysdba
2. createdirectory dump as 'c:\dump';
3. grantread,write on directory dump to public;
4. createtemporary tablespace tem_space tempfile 'D:\dump\xe\tem_space.dbf' size50m autoextend on next 50m maxsize 20480m extent management local;
5. createtablespace sungard datafile 'c:\dump\xe\sungard.dbf' size 50M autoextend onnext 50M maxsize 20480M;
6. create user trunk identified by pass default tablespace sungard temporary tablespacetem_space;
7. grantconnect,resource,dba to trunk;
cmd:
impdpsystem/pass directory=dump dumpfile=nxg_it.dmp REMAP_SCHEMA=nxg_it:trunkfull=y;
ps: REMAP_SCHEMA = [dump文件对应的user]:[自己数据库新建的user], 同理 REMAP_TABLESPACE
相关文章推荐
- oracle 使用随笔
- VBA读写Oracle的Blob数据
- ORACLE中伪表 dual 的用法
- oracle字符集问题
- 读取oracle sequence 的currval
- 【转载】怎样把Oracle的数据导入到SQLServer2005中
- 7.28 Oracle的 dblink
- Oracle正则表达式小结
- [SQL]-Oracle trunc()函数的用法
- Oracle数据库使用nfs挂载的盘执行expdp说明(Linux环境下)
- 查看oracle执行计划的两种方法
- Oracle 11gR2 RAC alert_+ASM1.log出现WARNING: failed to online diskgroup resource ora.CRS.dg (unable to
- sqoop使用报告:安装、向oracle导数据
- Oracle 12c以下版本RAC与Redhat Linux的avahi-daemon服务的水火不容
- oracle游标
- oracle增删改查操作
- Oracle Sequence自动补全指定位数
- Mysql迁移到Oracle简单记录
- Oracle11gR2 sqlplus中可以执行上键查询backspace删除
- Oracle11gR2 RAC voting disk error