oracle使用数据泵导入导出dmp文件

数据库导出

cmd运行

expdp pdgh_hb/[email protected]:11521/orcl  dumpfile =pdgh_Db100_1205.dmp

expdp会导出到数据库所在服务器中dpdump文件夹中

oracle使用数据泵导入导出dmp文件_第1张图片

如果要导入到本地使用

exp pdgh_hb/[email protected]:11521/orcl file=C:/Users/Administrator/Desktop/dump/test.dmp log=C:/Users/Administrator/Desktop/dump/gd_base.log 

导入

  • 创建泵目录
create directory beng as 'E:\DATADMP'; --必须存在 DATADMP目录文件夹(存放dmp的地方)
  • 授权泵目录给用户
Grant read,write on directory beng to factory;
  • cmd运行导入语句

将dmp文件放入泵目录

impdp pdgh_hb/[email protected]:1521/orcl directory=beng dumpfile=PDGH_DB100_1205.DMP  schemas=pdgh_hb

 

你可能感兴趣的:(#,数据库mysql,oracle,mycat,读写分离)