记录一次jdbc连接oracle失败的原因
ERROR [RMI TCP Connection(3)-127.0.0.1] - init datasource error
java.sql.sqlException: Listener refused the connection with the following error:ORA-12505,TNS:listener does not currently know of SID given in connect descriptor
jdbc配置如下:
jdbc.driverClassName=oracle.jdbc.driver.OracleDriver jdbc.url=jdbc:oracle:thin:@192.168.118.197:1521:orcl jdbc.username=learn_in jdbc.password=123456
下面为正确的:
原文链接:https://www.f2er.com/oracle/210984.htmljdbc.driverClassName=oracle.jdbc.driver.OracleDriver jdbc.url=jdbc:oracle:thin:@//192.168.118.197:1521/orcl jdbc.username=learn_in jdbc.password=123456