Oracle11g导入,导出, 导出空表问题

Oracle11g导入,导出, 导出空表问题

  1. 执行下面sql,标记空表
 select 'alter table '||table_name||' allocate extent;' from user_tables where num_rows=0` 
  1. 导出:使用CMD窗口执行导出语句,导出dmp格式,导出到E盘
 `exp userName/userPassword@127.0.0.1:1521/orcl file=E:\xxx.dmp`
  1. 导入:使用CMD窗口执行导入语句
  imp userName/userPassword@192.168.135.1:1521/orcl file=E:\xxx.dmp full=y ignore=y;
  1. 指定表导出(在导出的基础上加上tables=(表名1,表名2))
`exp userName/userPassword@127.0.0.1:1521/orcl file=E:\xxx.dmp` tables=(res_user,res_rule)

猜你喜欢

转载自blog.csdn.net/qq_33415990/article/details/113475437