- 第一种方式(自己安装过oracle数据库):
1.配置plsql的连接(可以理解找到一个tnsnames.ora,然后这里配置远程数据库的路径)
2.tnsnames.ora(可以在原来后的面追加)
# tnsnames.ora Network Configuration File: D:\app\ssss\product\11.2.0\dbhome_2\network\admin\tnsnames.ora
# Generated by Oracle configuration tools.
orcl2 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.66.145 )(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = dbname )
)
)
3.登录(数据库对应的应该是tnsnames.ora的唯一标识,等于号前面的,不是SEARVICE_NAME)
- 第二种方式()
参考大佬:https://www.cnblogs.com/JulesHello/p/6170678.html
https://blog.csdn.net/hr541659660/article/details/51683189