--创建目标库dblink create database link 目标库 connect to 账号 identified by "密码" using ‘ip地址:端口/目标库‘; --查询创建的dblink select owner,object_name from dba_objects where object_type=‘DATABASE LINK‘; --验证dblink select * from [email protected]目标库; 同步数据 merge INTO 目标库中的表@目标库b USING 源库表 a ON (b.id=a.id) when matched then update set b.name=a.name, ... when not matched then insert values (a.name, ...) WHERE a.xx= ‘xx‘; 提交 commit;
时间: 2024-09-30 14:35:20