title: Oracle SID and Service name; connection problems
body: <p>I'm trying to connect to oracle db on remote server through sql developer. I copied the connection details to tnsnames and I'm able to connect to the db. </p>
  
  <p>However i have another db application which is same as sqldeveloper and when I try to make a connection, I keep getting this error. This application uses oracle jdbc thin client which requires hostname and SID. </p>
  
  <p>I got the below error:</p>
  
  <p>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</p>
  
  <p>While troubleshooting, I changed the tns option in sqldeveloper and I have selected basic option to find out what went wrong and I realized that I'm able to connect to it because of the correct service name and not able to connect to the db via SID name even through sqldeveloper. </p>
  
  <p>I have used some db queries to find out SID name but still i keep getting the same error. Please help me troubleshoot. </p>
  
  <p>Thanks for your time..</p>