Linux 中 Oracle dmp 檔案匯入匯出

來源:互聯網
上載者:User

標籤:

a. 使用者名稱 system 密碼 manager 匯出到D:/daochu.dmp中

exp system/[email protected] file=d:/daochu.dmp full=y 

b. 將資料庫中 system 使用者與 sys 使用者的表匯出

exp system/[email protected] file=d:/daochu.dmp owner=(system,sys) 

c. 將資料庫中的表 inner_notify、notify_staff_relat匯出

exp aichannel/[email protected] file= d:/data/newsmgnt.dmp tables=(inner_notify,notify_staff_relat) 

d. 將資料庫中的表 table1 中的欄位 filed1 以"00"打頭的資料匯出

exp system/[email protected] file=d:/daochu.dmp tables=(table1) query=/" where filed1 like ‘00%‘/" 

對於壓縮,既用 winzip 把 dmp 檔案可以很好的壓縮,也可以在上面命令後面 加上 compress=y 來實現。

匯出 DMP檔案適用於,大型資料庫完整遷移,遷移前後的資料庫字元集要求比較嚴格,對CLOB欄位支援不太友好。

對於小資料的匯出其實用 PLSQL 能做的更好,更快,匯出的SQL也很直觀。

對於本機安裝了oracle 用戶端,可以直接將 DMP 檔案匯出到本地,如果是沒有安裝,匯出的檔案是在linux 伺服器上面。

需要用遠程工具【WINSCp,PINTY.....】串連下載下來。

e. 將 D:/daochu.dmp 中的資料匯入 TEST資料庫中。

imp system/[email protected] file=d:/daochu.dmp imp aichannel/[email protected] full=y file=file= d:/data/newsmgnt.dmp ignore=y 

上面可能有點問題,因為有的表已經存在,然後它就報錯,對該表就不進行匯入,後面添加 ignore=y。 

f. 將 d:/daochu.dmp中的表table1 匯入

imp system/[email protected] file=d:/daochu.dmp tables=(table1)

Linux 中 Oracle dmp 檔案匯入匯出

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.