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

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

Do you know how to solve this issue? Write a tip to help other users and build your expert profile.

Solutions on the web

via Stack Overflow by Fitz
, 1 year ago
Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
via Oracle Community by 937637, 1 year ago
The Network Adapter could not establish the connection
via Geographic Information Systems by Jay Cummins
, 1 year ago
Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
via stackexchange.com by Unknown author, 1 year ago
Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
via Stack Overflow by user591790
, 9 months ago
Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
via Coderanch by ven jovovich, 11 months ago
Listener refused the connection with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor
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
at oracle.net.ns.NSProtocol.connect(NSProtocol.java:386)
at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1054)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:308)
at oracle.jdbc.driver.PhysicalConnection.(PhysicalConnection.java:536)
at oracle.jdbc.driver.T4CConnection.(T4CConnection.java:228)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:521)
at java.sql.DriverManager.getConnection(Unknown Source)
at theOpenTutorials.TestRealDatabase.main(TestRealDatabase.java:22)

Users with the same issue

Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 2 years ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.