美文网首页我爱编程
oracle 导入导出数据

oracle 导入导出数据

作者: 玲珑花 | 来源:发表于2017-06-02 16:23 被阅读0次

oracle 导入导出数据

1.普通 imp/dmp

--导入DMP文件

-imp userid=用户名/密码@orcl file=d:\nc60.dmp full=y

2.使用数据泵方式导入导出

-- oracle使用impdp方式导入数据

--导入时必须先创建文件夹路径

create or replace directory bao as 'F:\app\Administrator\oradata\orcl\eoms';

--给使用的用户授权(读写权限)

Grant read,write on directory bao to eoms;

--mpdp 用户名/密码 schemas=要导入的用户(即是使用expdp导出的用户)

--directory=创建的文件夹名称(directory_name)

--dumpfile=test.dmp(要放入到directory_path路径下) logfile=imp.log(可以不写)

impdp eoms/zhongway directory=BAO dumpfile=EMOS.DMP parallel=5

--导出expdp工具使用方法:

--创建文件夹路径

create or replace directory flodername as 'F:\app\Administrator\oradata\orcl\lisatest;

--授权操作文件夹

Grant read,write on directory flodername to username;

--整个文件 schemas=要导入的用户

expdp username/password@localhost schemas=username dumpfile=expdp2.dmp

directory=flodername

--其中表

expdp username/password@localhost schemas=username dumpfile=expdp2.dmp

directory=flodername include=table:"like 'CT%'"

相关文章

网友评论

    本文标题:oracle 导入导出数据

    本文链接:https://www.haomeiwen.com/subject/dlyufxtx.html