(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = bylw)
)
)’;
第二种是把第一种配置在tnsnames.ora文件中的信息,直接放在创建dblink语句后面。第一种情况tnsnames.ora文件中信息如下:
bylw =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.5)(PORT = 1521))
)
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = bylw)
)
)