在Orcle服务在服务器本机上正常运行的情况下,并且Orcl服务器端口开启和防火墙允许的情况下,进行以下操作:
1. 修改Orcl监听文件
(路径不分大小写D:Oracleproduct11.2.0dbhome_1 etworkadminlistener.ora)
SID_LIST_LISTENER = (SID_LIST = (SID_DESC = (SID_NAME = CLRExtProc) (ORACLE_HOME = D:Oracleproduct11.2.0dbhome_1) (PROGRAM = extproc) (ENVS = "EXTPROC_DLLS=ONLY:D:Oracleproduct11.2.0dbhome_1inoraclr11.dll") ) ) LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = **(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) //加入这部分** (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) ) ) ADR_BASE_LISTENER = D:Oracle
2. 查看服务名称,并记录下来
路径不分大小写D:Oracleproduct11.2.0dbhome_1 etworkadmin nsnames.ora)
LISTENER_ORCL = (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) ORACLR_CONNECTION_DATA = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) ) (CONNECT_DATA = (SID = CLRExtProc) (PRESENTATION = RO) ) ) ORCL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) **(SERVICE_NAME = orcl) //记下这部分** ) )
3.进行数据库设置
4.根据序号来进行。
5号,即Service 填写第2步中记录下来的服务名
6号 是连接Orcl的驱动 即ojdbc14_11.jar包(根据自己项目的情况选用版本)
7号测试连接,成功点ok即可
(若不知如何加入jar驱动,往下看)
5.点击第4步中的6号,点击图中位置加入
在测试成功后入后看
6.右键连接即可加入table
到此这篇关于IntelliJ DataGrip Oracle 11g远程连接的文章就介绍到这了,更多相关DataGrip Oracle 11g远程连接内容请搜索服务器之家以前的文章或继续浏览下面的相关文章希望大家以后多多支持服务器之家!
原文链接:https://blog.csdn.net/sinat_22131157/article/details/52607545