如今須要同步OA系統中的部門和用戶數據給其餘系統用。ide
建立DBLINK:spa
1.賦權:grant create public database link to dbusername; 同步
2,建立:-- Drop existing database link
create public database link DB_OA
connect to XXX identified by XXXXXXX
using '(DESCRIPTION =(ADDRESS_LIST =(ADDRESS =(PROTOCOL = TCP)(HOST = XXX.XX.XX.X)(PORT = 1521)))(CONNECT_DATA =(SERVICE_NAME = orcl)))';table
3.使用腳本date
create table tb_oa_department as
select t.*,sysdate synchronize_time from T_DEPARTMENT@DB_OA t;select