oracle exp/imp 導入導出命令

          (1)表方式,將指定表的數據導出/導入。
          導出:
          導出一張或幾張表:

          代碼
          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log tables=table1,table2 

          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log tables=table1,table2

          如果是分區表

          代碼
          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log tables=table1:tablespaces1,table2:tablespaces2 

          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log tables=table1:tablespaces1,table2:tablespaces2

          導出某張表的部分數據

          代碼
          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log tables=table1 query=\”where col1=\’…\’  
          and col2 \<…\” 

          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log tables=table1 query=\”where col1=\’…\’
          and col2 \<…\”
          導入:
          導入一張或幾張表

          代碼
          $  imp  user/pwd  file=/dir/xxx.dmp  log=xxx.log  tables=table1,table2  fromuser=dbuser touser=dbuser2 commit=y ignore=y 

          $  imp  user/pwd  file=/dir/xxx.dmp  log=xxx.log  tables=table1,table2  fromuser=dbuser touser=dbuser2 commit=y ignore=y
          如果是分區表

          代碼
          $  imp  user/pwd  file=/dir/xxx.dmp  log=xxx.log  tables=table1:tablespaces1,table2:tablespaces2  fromuser=dbuser touser=dbuser2 commit=y ignore=y 

          $  imp  user/pwd  file=/dir/xxx.dmp  log=xxx.log  tables=table1:tablespaces1,table2:tablespaces2  fromuser=dbuser touser=dbuser2 commit=y ignore=y

          (2)用戶方式,將指定用戶的所有對象及數據導出/導入。
          導出:

          代碼
          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log owner=(xx, yy) 

          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log owner=(xx, yy)
          只導出數據對象,不導出數據  (rows=n )

          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log owner=user rows=n
          導入:

          代碼
          imp  user/pwd  file=/dir/xxx.dmp  log=xxx.log  fromuser=dbuser  touser=dbuser2  
          mmit=y ignore=y 

            imp  user/pwd  file=/dir/xxx.dmp  log=xxx.log  fromuser=dbuser  touser=dbuser2
          commit=y ignore=y
          (3)全庫方式,將數據庫中的所有對象導出/導入導出:

          代碼
          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log full=ycommit=y ignore=y 

          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log full=ycommit=y ignore=y
          導入:

          代碼
          $ imp user/pwd file=/dir/xxx.dmp log=xxx.log fromuser=dbuser touser=dbuser2



          posted on 2010-07-14 16:51 魯勝迪 閱讀(53955) 評論(2)  編輯  收藏

          評論

          # re: oracle exp/imp 導入導出命令[未登錄] 2015-07-31 11:54 曉東


          1導出用戶system密碼1234 服務器zyd 的 table1 table2表

          Exp system/1234@zyd file=E:\file\wenjia.dmp tables=table1,table2


          2用戶模式 導出用戶system的所有對象
          Exp system/1234@zyd (buffer=64000) file=E:\file\dkkd.dmp owner=system

          3完全模式

          Exp system/1234@zyd (butter=64000) file=E:\file\dkk.dmp full=y


          Imp 完全模式
          Imp system/1234@zyd (butter=6400) file=E:\file\dkk.dmp full=y

          用戶模式
          Imp system/12342zyd (butter) file=E:\file\dkkk.dmp fromuser=gadate001
          Touser=system

          表模式
          Imp system/1244@zyd file=E:\3123.dmp   回復  更多評論   

          # 邏輯很清晰,完美解決俺的問題,很實用的說 2015-08-18 11:19 而又

          邏輯很清晰,完美解決俺的問題,很實用的說  回復  更多評論   


          只有注冊用戶登錄后才能發表評論。


          網站導航:
           
          <2010年7月>
          27282930123
          45678910
          11121314151617
          18192021222324
          25262728293031
          1234567

          導航

          統計

          常用鏈接

          留言簿(4)

          隨筆分類

          隨筆檔案

          文章分類

          新聞分類

          搜索

          最新評論

          閱讀排行榜

          評論排行榜

          主站蜘蛛池模板: 宣汉县| 滨州市| 中山市| 婺源县| 南乐县| 肇源县| 阳东县| 偏关县| 扶绥县| 静宁县| 沙湾县| 通榆县| 台山市| 秭归县| 青冈县| 石门县| 荣成市| 金乡县| 营山县| 屯昌县| 金湖县| 绥芬河市| 巴马| 嘉黎县| 襄城县| 大宁县| 凤山县| 扬州市| 蒲江县| 伊金霍洛旗| 双桥区| 远安县| 江北区| 手游| 汝阳县| 聂拉木县| 杂多县| 寿阳县| 历史| 兴化市| 建德市|