您的位置:首页 > 数据库 > Oracle

oracle dblink 创建使用 垮库转移数据

2015-09-17 11:22 330 查看
create  database link JTKHJFDB
connect to khjf identified by hello
using '(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.196.57.197)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = JTKHJFDB)
)
)'
;
select  party_id,realname from tbl_person ;
select * from  t_customer@JTKHJFDB ;
delete from t_customer@JTKHJFDB
create synonym remote_seq for PK_SEQ@JTKHJFDB;
insert into t_customer@JTKHJFDB(ID, uuid,name) select remote_seq.nextval, to_char(party_id),realname from tbl_person;
Drop   DATABASE LINK JTKHJFDB;
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: