最新文章专题视频专题问答1问答10问答100问答1000问答2000关键字专题1关键字专题50关键字专题500关键字专题1500TAG最新视频文章推荐1 推荐3 推荐5 推荐7 推荐9 推荐11 推荐13 推荐15 推荐17 推荐19 推荐21 推荐23 推荐25 推荐27 推荐29 推荐31 推荐33 推荐35 推荐37视频文章20视频文章30视频文章40视频文章50视频文章60 视频文章70视频文章80视频文章90视频文章100视频文章120视频文章140 视频2关键字专题关键字专题tag2tag3文章专题文章专题2文章索引1文章索引2文章索引3文章索引4文章索引5123456789101112131415文章专题3
当前位置: 首页 - 科技 - 知识百科 - 正文

RAC创建DBlink并使用impdp抽取源库数据

来源:懂视网 责编:小采 时间:2020-11-09 10:53:01
文档

RAC创建DBlink并使用impdp抽取源库数据

RAC创建DBlink并使用impdp抽取源库数据:RAC创建DBlink并使用impdp抽取源库数据 赋权并创建dblink [plain] view plaincopyprint[Oracle@zhongwc1 ~]$ sqlplus / as sysd RAC创建DBlink并使用impdp抽取源库数据 赋权并创建dblink [plain] view plaincopypri
推荐度:
导读RAC创建DBlink并使用impdp抽取源库数据:RAC创建DBlink并使用impdp抽取源库数据 赋权并创建dblink [plain] view plaincopyprint[Oracle@zhongwc1 ~]$ sqlplus / as sysd RAC创建DBlink并使用impdp抽取源库数据 赋权并创建dblink [plain] view plaincopypri

RAC创建DBlink并使用impdp抽取源库数据 赋权并创建dblink [plain] view plaincopyprint?[Oracle@zhongwc1 ~]$ sqlplus / as sysd

RAC创建DBlink并使用impdp抽取源库数据

赋权并创建dblink


[plain] view plaincopyprint?
[Oracle@zhongwc1 ~]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Mon Feb 4 10:26:45 2013

Copyright (c) 1982, 2011, Oracle. All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options

SQL> grant create database link to zwc;

Grant succeeded.

SQL> conn zwc/
Enter password:
Connected.
SQL> show user
USER is "ZWC"
SQL> select tname from tab;

no rows selected

[oracle@zhongwc1 ~]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Mon Feb 4 10:26:45 2013

Copyright (c) 1982, 2011, Oracle. All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options

SQL> grant create database link to zwc;

Grant succeeded.

SQL> conn zwc/
Enter password:
Connected.
SQL> show user
USER is "ZWC"
SQL> select tname from tab;

no rows selected[plain] view plaincopyprint?
create public database link ZWC
connect to zhongwc identified by zhongwc
using '(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.201)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = ZWC)
)
9 )';

Database link created.

SQL> select * from dual@zwc;

D
-
X

SQL> show user
USER is "ZWC"
SQL> select tname from tab;

no rows selected

--------------------------------------------------------------------------------------

SQL> select tname from tab@zwc;

TNAME
------------------------------
T_ZHONGWC

SQL> select count(*) from t_zhongwc;
select count(*) from t_zhongwc
*
ERROR at line 1:
ORA-00942: table or view does not exist


SQL> select count(*) from t_zhongwc@zwc;

COUNT(*)
----------
75453

SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
[oracle@zhongwc1 ~]$ impdp system/oracle network_link=zwc schemas=zhongwc remap_schema=zhongwc:zwc

Import: Release 11.2.0.3.0 - Production on Mon Feb 4 10:47:45 2013

Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options
Starting "SYSTEM"."SYS_IMPORT_SCHEMA_01": system/******** network_link=zwc schemas=zhongwc remap_schema=zhongwc:zwc
Estimate in progress using BLOCKS method...
Processing object type SCHEMA_EXPORT/TABLE/TABLE_DATA
Total estimation using BLOCKS method: 9 MB
Processing object type SCHEMA_EXPORT/USER
ORA-31684: Object type USER:"ZWC" already exists
Processing object type SCHEMA_EXPORT/SYSTEM_GRANT
Processing object type SCHEMA_EXPORT/ROLE_GRANT
Processing object type SCHEMA_EXPORT/DEFAULT_ROLE
Processing object type SCHEMA_EXPORT/PRE_SCHEMA/PROCACT_SCHEMA
Processing object type SCHEMA_EXPORT/TABLE/TABLE
. . imported "ZWC"."T_ZHONGWC" 75453 rows
Job "SYSTEM"."SYS_IMPORT_SCHEMA_01" completed with 1 error(s) at 10:48:32

create public database link ZWC
connect to zhongwc identified by zhongwc
using '(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.201)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = ZWC)
)
9 )';

Database link created.

SQL> select * from dual@zwc;

D
-
X

SQL> show user
USER is "ZWC"
SQL> select tname from tab;

no rows selected

SQL> select tname from tab@zwc;

TNAME
------------------------------
T_ZHONGWC

文档

RAC创建DBlink并使用impdp抽取源库数据

RAC创建DBlink并使用impdp抽取源库数据:RAC创建DBlink并使用impdp抽取源库数据 赋权并创建dblink [plain] view plaincopyprint[Oracle@zhongwc1 ~]$ sqlplus / as sysd RAC创建DBlink并使用impdp抽取源库数据 赋权并创建dblink [plain] view plaincopypri
推荐度:
标签: 创建 使用 数据
  • 热门焦点

最新推荐

猜你喜欢

热门推荐

专题
Top