Oracle impdp導入dmp文件(windows)
- 1、連接數據庫
- 2、創建與導出的模式相同名稱的用戶WIRELESS2,并賦予權限
- 3、創建directory 的物理目錄f:\radio\dmp,并把.dmp文件放進去
- 4、連接新用戶WIRELESS2
- 5、創建表空間的物理目錄F:\radio\tablespaces,并創建與導出的表空間名稱相同的表空間WIRELESS
- 6、退出數據庫
- 7、導入數據庫
本文借鑒自:https://blog.csdn.net/h18300103614/article/details/120969059
1、連接數據庫
sqlplus root/123456@localhost:1521/orcl as sysdba
2、創建與導出的模式相同名稱的用戶WIRELESS2,并賦予權限
create user WIRELESS2 identified by WIRELESS2;
grant dba to WIRELESS2;
grant read,write on directory dmp to WIRELESS2;
3、創建directory 的物理目錄f:\radio\dmp,并把.dmp文件放進去
create or replace directory dmp as ‘f:\radio\dmp’;
4、連接新用戶WIRELESS2
connect WIRELESS2/WIRELESS2@localhost:1521/orcl;
5、創建表空間的物理目錄F:\radio\tablespaces,并創建與導出的表空間名稱相同的表空間WIRELESS
create tablespace WIRELESS datafile ‘F:\radio\tablespaces\WIRELESS.ora’ size 1m autoextend on;
6、退出數據庫
exit;
7、導入數據庫
impdp WIRELESS2/WIRELESS2@localhost:1521/orcl REMAP_SCHEMA = WIRELESS2:WIRELESS2 table_exists_action = replace directory=dmp dumpfile=20240315.DMP PARALLEL=6 logfile=ImpUser0120210325.log