特別說明:導入、導出數據要在oracle目錄的bin目錄下,去導;即在doc下
導出表
(1)導出自己的表
exp userid = scott/tiger@myoral tables =(emp,map) file=d:el.dmp 導出emp和map表
(2)導出表結構
exp userid = scott/tiger@myoral tables =(emp,map) file=d:el.dmp rows=n與導出表只是多
了一個rows=n.
(3)導出數據庫
exp userid = system/manager@myora1 full = y inctype = complete file = d: aa.bmp;
========================
導入表
(1)導入自己的表
imp userid = scott/tiger@myor tables = (emp) file=d:/xx.dmp;
(2) 導入表到其他用戶
要求該用戶具有dba的權限,或是imp_full_database
imp userid = system/manager@myor tables=(emp) file=d:/xx.dmp touser=scott
(3) 導入表的結構
只導入表的結構而不導入數據
imp userid = soctt/tiger@myor tables=(emp) file=d:/xxx.dmp rows=n;
(4) 導入數據
如果對象(比如表)已經存在可以只導入表的數據
imp userid = scott/tiger@myor tables=(emp) file=d:/xxx.dmp ignore=y
=============================
導入方案
導入方案是指使用import工具將文件中的對象和數據導入到一個或是多個方案中。如果要導入其它方案,要求該用戶具有dba的權限,或是imp_full_database
(1) 導入自身的方案
imp userid = scott/tiger file=d:/xxx.dmp
(2) 導入其它方案
imp userid = system/manager file=d:/xxx.dmp fromuser = system touser = scott;
=====================