Oracle12c的數據庫向11g導進的方法

從oracle 12c 備份(expdp)出來的包,還原到11g裏,想一想都知道會有兼容性問題。sql

果不其然,報錯了:數據庫

ORA-39142: 版本號 4.1 (在轉儲文件 「叉叉叉.expdp」 中) 不 兼容oracle

之類code

後來才知道,在12C中備份出來時,應指定版本信息,例如我要導進11g的庫(具體版本爲11.1.0.6.0,打開sqlplus就能看到),則version=11.1.0.6.0io

語句:table

在12C備份class

expdp system/password@SID12c directory=dbbak dumpfile=20160321.expdp logfile=20160321.log schemas=leftfist version=11.1.0.6.0

在11g中還原兼容性

impdp sys/password@SID11g directory=dbbak dumpfile=20160321.expdp logfile=20160321.log schemas=leftfist table_exists_action=replace

固然這裏面忽略了建立備份文件存放目錄dbbak,建立表空間、用戶等細節。後續有時間會持續給你們帶來相關知識介紹,但願本文給你們介紹的Oracle12c的數據庫向11g導進的方法對你們有所幫助!file

相關文章
相關標籤/搜索