文档介绍:还不算晕的专栏
热衷于ORACLE数据库,博客内的实验环境为:LINUX+ORACLE
;内容基本为原创,少量转载。欢迎指点、交
流!
使用EXPDP/IMPDP导入导出表中数据/元数据测试
分类: ORACLE实战 ORACLE RMAN备份与恢复 2013-12-18 13:30 222人阅读评论(0) 收藏举报
EXPDPIMPDP
首先创建导出目录:  --更详细命令及参数,见:
http://blog./haibusuanyun/article/details/12584727
BYS@ bys3>create directory dir_dp as '/home/oracle/';
Directory created.
BYS@ bys3>grant read,write on directory dir_dp to public;
Grant eeded.
col privilege for a15
col directory_name for a15
col directory_path for a30
SELECT privilege, directory_name, DIRECTORY_PATH FROM user_tab_privs t, all_directories d  WHERE
(+) = ORDER BY 2, 1;    --可以使用此语句验证配置。
#######################################################
导出用户某个表测试:
只BYS用户下表定义不导出数据:
expdp bys/bys tables= directory=dir_dp dumpfile= logfile=
content=metadata_only
只BYS用户下数据不导出表定义:
expdp bys/bys tables=  directory=dir_dp dumpfile= logfile=
content=data_only
导出BYS用户下所有对象--content不写,默认是ALL.
expdp bys/bys tables=  directory=dir_dp file= logfile=
####################################################
导出整个用户下对象测试:
导出整个用户下对象的元数据:
expdp bys/bys schemas=bys  directory=dir_dp file= logfile= content=metadata_only
导出整个用户下的对象
expdp bys/bys schemas=bys  directory=dir_dp file= logfile=
#############################