Posted on 2008-12-09 00:40
陜西BOY 閱讀(100)
評論(0) 編輯 收藏
oracle知識
備份數據
1、獲取幫助:
exp help=y
2. 導出一個完整數據庫
exp
user/pwd@instance file=path full=y
示例:exp
system/system@xc file = c:/hehe fill =y
3 、導出一個或一組指定用戶所屬的全部表、索引和其他對象
exp system/manager file=seapark log=seapark owner=seapark exp system/manager file=seapark log=seapark owner=(seapark,amy,amyc,harold)
示例:exp
system/system@xc file=c:/hehe owner=uep
4、導出一個或多個指定表
exp system/manager file=tank log=tank tables=(seapark.tank,amy.artist)
示例:exp
system/system@xc file=c:/heh tables=(ueppm.ne_table)
恢復數據
1. 獲取幫助
2. 導入一個完整數據庫
imp system/manager file=bible_db log=dible_db full=y ignore=y
3. 導入一個或一組指定用戶所屬的全部表、索引和其他對象
imp system/manager file=seapark log=seapark fromuser=seapark
imp system/manager file=seapark log=seapark fromuser=(seapark,amy,amyc,harold)
4. 將一個用戶所屬的數據導入另一個用戶
imp system/manager file=tank log=tank fromuser=seapark touser=seapark_copy
imp system/manager file=tank log=tank fromuser=(seapark,amy) touser=(seapark1, amy1)
5. 導入一個表
imp system/manager file=tank log=tank fromuser=seapark TABLES=(a,b)