oracle exp/imp 導(dǎo)入導(dǎo)出命令

          (1)表方式,將指定表的數(shù)據(jù)導(dǎo)出/導(dǎo)入。
          導(dǎo)出:
          導(dǎo)出一張或幾張表:

          代碼
          $ 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

          如果是分區(qū)表

          代碼
          $ 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

          導(dǎo)出某張表的部分?jǐn)?shù)據(jù)

          代碼
          $ 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 \<…\”
          導(dǎo)入:
          導(dǎo)入一張或幾張表

          代碼
          $  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
          如果是分區(qū)表

          代碼
          $  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)用戶方式,將指定用戶的所有對象及數(shù)據(jù)導(dǎo)出/導(dǎo)入。
          導(dǎo)出:

          代碼
          $ 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)
          只導(dǎo)出數(shù)據(jù)對象,不導(dǎo)出數(shù)據(jù)  (rows=n )

          $ exp user/pwd file=/dir/xxx.dmp log=xxx.log owner=user rows=n
          導(dǎo)入:

          代碼
          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)全庫方式,將數(shù)據(jù)庫中的所有對象導(dǎo)出/導(dǎo)入導(dǎo)出:

          代碼
          $ 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
          導(dǎo)入:

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



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

          評(píng)論

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


          1導(dǎo)出用戶system密碼1234 服務(wù)器zyd 的 table1 table2表

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


          2用戶模式 導(dǎo)出用戶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   回復(fù)  更多評(píng)論   

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

          邏輯很清晰,完美解決俺的問題,很實(shí)用的說  回復(fù)  更多評(píng)論   


          只有注冊用戶登錄后才能發(fā)表評(píng)論。


          網(wǎng)站導(dǎo)航:
           
          <2010年7月>
          27282930123
          45678910
          11121314151617
          18192021222324
          25262728293031
          1234567

          導(dǎo)航

          統(tǒng)計(jì)

          常用鏈接

          留言簿(4)

          隨筆分類

          隨筆檔案

          文章分類

          新聞分類

          搜索

          最新評(píng)論

          閱讀排行榜

          評(píng)論排行榜

          主站蜘蛛池模板: 广安市| 崇文区| 牙克石市| 长子县| 盱眙县| 固阳县| 托里县| 黄石市| 通海县| 达拉特旗| 定结县| 富阳市| 桃园县| 天台县| 镇坪县| 中超| 都安| 满城县| 故城县| 偃师市| 叙永县| 泸州市| 广昌县| 社旗县| 门源| 荔浦县| 怀远县| 萝北县| 巴彦县| 正蓝旗| 延庆县| 忻城县| 新乡县| 广饶县| 五大连池市| 东丽区| 菏泽市| 南召县| 上思县| 宁蒗| 开封县|