1、创建本地的tnsname连接至另一台主机的实例。
2、创建dblink:
SQL> create public database link test_scott connect to scott identified by tiger using 'db_test';
Database link created.
3、测试dblink
SQL> select * from emp@test_scott;
。。 。。。
14 rows selected.
4、创建同义词,对用户透明
SQL> create synonym scottemp for emp@test_scott;
Synonym created.
SQL> select * from scottemp;
。。。。。。
14 rows selected.
阅读(4046) | 评论(0) | 转发(0) |