Tech Tips: ORA-12505, TNS:listener does not currently know of SID given in connect descriptor

Document created by MarcyNunns Employee on Jun 2, 2017
Version 1Show Document
  • View in full screen mode

Issue

 

1. Have JDBC step where I am making a call to an Oracle database with the Connection String of:

 

jdbc:oracle:thin:@{{SERVER}}:1521:{{SIDNAME}

 

2. When I test I get the error:


2017-06-01 21:44:26,341Z (14:44) [AWT-EventQueue-0] ERROR com.itko.util.swing.UserMessage - There was a SQLException: 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

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

 

Environment

 

All supported DevTest releases and platforms.

 

Cause

 

Connection string was formatted improperly.

 

Resolution

 

Used SQuirrel SQL Client to verify Oracle JDBC Connection String and getting the same error.


Realized needing to be making the Oracle JDBC call to the SERVICE and not the SID.


The format of the Connection String is different between calling the SID and calling the SERVICE.


Once the connection string was changed to call the SERVICE, the call was successful:

 

jdbc:oracle:thin:@{{SERVER}}:1521/{{SERVICENAME}

 

Additional Information

 

You can refer to the site.properties file for how to format a JDBC Connection String depending on the database you are calling from a SQL Database Execution (JDBC) step.

Attachments

    Outcomes