日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問(wèn) 生活随笔!

生活随笔

當(dāng)前位置: 首頁(yè) > 编程资源 > 编程问答 >内容正文

编程问答

Chapter18-Export and Import Utilities

發(fā)布時(shí)間:2025/6/17 编程问答 22 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Chapter18-Export and Import Utilities 小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.

1、export和import操作的.dmp文件,是一種二進(jìn)制文件;面對(duì)一些小型的數(shù)據(jù)庫(kù),可以應(yīng)付;但是對(duì)于那些大型的數(shù)據(jù)庫(kù),就有些吃力了;Import和export將逐漸的被淘汰;

  • exp.exe->exedp.exe
  • imp.exe->impdp.exe
  • *.dmp文件時(shí)平臺(tái)無(wú)關(guān)性的;

2、Before Your Use Of Exp/Imp

  • Run the catexp.sql or catalog.sql script(如果DBA是用DBCA工具創(chuàng)建的數(shù)據(jù)庫(kù),Oracle ?server 會(huì)自動(dòng)執(zhí)行上述兩個(gè)腳本;如果是手工創(chuàng)建的數(shù)據(jù)庫(kù),則需要手工執(zhí)行上述兩個(gè)腳本)

3、Methods to invoke Exp/Imp

  • Command-line interface
  • An interactive mode
  • Parameter files
  • Oracle Enterprise Manager

4、exp命令使用

  • exp a1/a1@DB200 file=a1.dmp owner=a1 log=a1.log

5、Export Modes

Table ModeUser ModeTablespace ModeFull Database Mode

Table definitions

Table data(all or selected rows)

Owner`s table grants

Owner`s table indexes

Table constraints

Tables definitions

Tables data

Owner`s grants

Owner`s indexes

Tables constraints

Table definitions

Grants

Indexes

Table constraints Triggers

?

Table definitions

Tables data

Grants

Indexes

Tables contraints

?

?

?

?

?

?

?

  • Full Database Mode基本上被RMAN或者一些第三方工具給代替;
  • Tablespace Mode擁有特有的用途;
  • Table Mode或者User Mode比較常見(jiàn);

6、Invoking Export

Syntax:exp keyword=value,value2,...,valuen

Example:

  • exp hr/hr TABLES=employees,departments rows=y file=exp1.dmp
    • tables=employees,departments表示只導(dǎo)出這兩張表
    • rows=y,表示只導(dǎo)出數(shù)據(jù)
  • exp system/manager owner=hr direct=y file=expdata.dmp
    • owner=hr,表示導(dǎo)出hr這個(gè)用戶(hù)的所有數(shù)據(jù)信息
  • exp \'username/password as sysdba'\ transport_tablespace=y tablespaces=ts_emp log=ts_emp.log
    • \'username/password as sysdba'\表示以sysdba身份導(dǎo)出數(shù)據(jù)
    • transport_tablespace=y表示只導(dǎo)出表空間的相關(guān)的數(shù)據(jù)字典信息(這個(gè)數(shù)據(jù)量很少),而表空間上的數(shù)據(jù)不會(huì)導(dǎo)出;
    • tablespaces=ts_emp,表示要導(dǎo)出的表空間名稱(chēng)

7、How the Transportable TS Modes Works

?

?

簡(jiǎn)述:通過(guò)Transportable模式進(jìn)行exp操作,實(shí)際上導(dǎo)出的.dmp文件僅僅是被導(dǎo)出tablespace的相關(guān)的數(shù)據(jù)字典信息(也就是此tablespace在system dictionary中的登記信息),而實(shí)際tablespace中的數(shù)據(jù)信息,則是通過(guò)中介os copy的模式進(jìn)行的;如此以來(lái)可以大大提高效率;

8、導(dǎo)出數(shù)據(jù)的兩種方式

  • Direct Paht
  • Convention Paht

9、grant imp_full_database to u2

給用戶(hù)u2授權(quán)imp_full_database命令,使其能夠?qū)肫渌脩?hù)的dmp文件.

轉(zhuǎn)載于:https://www.cnblogs.com/arcer/archive/2013/03/21/2973055.html

總結(jié)

以上是生活随笔為你收集整理的Chapter18-Export and Import Utilities的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。

如果覺(jué)得生活随笔網(wǎng)站內(nèi)容還不錯(cuò),歡迎將生活随笔推薦給好友。