当前位置: 首页 > news >正文

Oracle 数据库通过exp/imp工具迁移指定数据表

项目需求:从prod数据库迁移和复制2个表(BANK_STATE,HBS)的数据到uat数据库环境。

数据库版本:Oracle Database 19c Enterprise Edition Release 19.0.0.0.0

迁移工具:客户端exp/imp工具

 

-- 执行命令 从Prod数据库导出数据

exp username/password@server_ip:1521/service_name TABLES=(BANK_STATE,HBS) file=C:\oracle\dump\cola_tables_20250324.dmp log=C:\oracle\dump\cola_tables_20250324_exp.log

-- Login DB  进入sqlplus

sqlplus username/password@server_ip:1521/service_name


-- 提前在UAT环境删掉已经存在的表

DROP TABLE BANK_STATE;
DROP TABLE HBS;

-- 执行命令 将dump文件导入到uat数据库

  imp username/password@server_ip:1521/service_name file=C:\oracle\dump\cola_tables_20250324.dmp log=C:\oracle\dump\cola_tables_20250325_imp.log tables=(BANK_STATE,HBS)

导出日志记录

Connected to: Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.22.0.0.0
Export done in US7ASCII character set and AL16UTF16 NCHAR character set
server uses AL32UTF8 character set (possible charset conversion)

About to export specified tables via Conventional Path ...
. . exporting table                     BANK_STATE     307313 rows exported
EXP-00091: Exporting questionable statistics.
. . exporting table                            HBS    1377128 rows exported
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
EXP-00091: Exporting questionable statistics.
Export terminated successfully with warnings.

导入日志记录


Connected to: Oracle Database 19c Enterprise Edition Release 19.0.0.0.0 - Production
Version 19.22.0.0.0

Export file created by EXPORT:V19.00.00 via conventional path
import done in US7ASCII character set and AL16UTF16 NCHAR character set
import server uses AL32UTF8 character set (possible charset conversion)
IMP-00403: 

Warning: This import generated a separate SQL file "C:\oracle\dump\cola_tables_20250325_imp_sys.sql" which contains DDL that failed due to a privilege issue.

. importing COLADB's objects into COLADB
. importing COLADB's objects into COLADB
. . importing table                   "BANK_STATE"     307313 rows imported
. . importing table                          "HBS"    1377128 rows imported
Import terminated successfully with warnings.

 

 

 

 

相关文章:

  • 文件操作 说明
  • python deepseek AI
  • ShapeCrawler:.NET开发者的PPTX操控魔法
  • STM32中不同FLASH的芯片启动文件选择规则
  • vue 封装 Axios菜鸟教程
  • STM32C011 进入停止模式和待机模式
  • 昇腾MindIE 限制非首token时延(TPOT)的极限吞吐
  • Windows命令提示符(CMD) 的常用命令分类整理
  • Google Benchmark性能测试
  • 质检LIMS系统在粮油加工企业的应用 粮油质检LIMS系统应用的痛点
  • AP CSA FRQ Q2 Past Paper 五年真题汇总 2023-2019
  • 单多表查询练习
  • jmm-java内存模型
  • 工厂模式a
  • 习题4-9 打印菱形图案
  • 全分辨率免ROOT懒人精灵-自动化编程思维-设计思路-实战训练
  • Arduino、ESP32驱动BME688环境传感器(环境传感器篇)
  • 模拟curl的回调函数实现返回结构体
  • 基于Spring Boot的ONLY在线商城系统设计与实现的设计与实现(LW+源码+讲解)
  • Ubuntu xinference部署本地模型bge-large-zh-v1.5、bge-reranker-v2-m3
  • 李家超:明日起香港特区护照持有人可免签入境阿联酋
  • 奥迪车加油时频繁“跳枪”维修两年未解决,4S店拒退换:可延长质保
  • “大鼻子情圣”德帕迪约因性侵被判缓刑,还有新的官司等着他
  • 从这些电影与影像,看到包容开放的上海
  • 多家中小银行存款利率迈入“1时代”
  • 新华时评:中美经贸会谈为全球经济纾压增信