Home » RDBMS Server » Networking and Gateways » Able to connect via SERVICE_NAME, but not SID
Able to connect via SERVICE_NAME, but not SID [message #192116] Mon, 11 September 2006 01:13 Go to next message
ericonice
Messages: 2
Registered: September 2006
Junior Member
Hi,

I am attempting to connect to an oracle database which I unfortunately know very little about (I can not even view the listener.ora file for that database).

I am able to connect to it (via JDBC) if I give a URL which specifies the SERVICE_NAME, something like:
"jdbc:oracle:thin:@(DESCRIPTION=
(ADDRESS=(PROTOCOL=TCP)(HOST=host)(PORT=1521))
(CONNECT_DATA=(SERVICE_NAME=ora92.world)))"

However, if I connect just using the SID, I get an ORA-12505 error:
"jdbc:oracle:thin:@host:1521:ora92"

My question is if it's possible to have a listener be able accept connections via service name, but disable them via SID; and if so, how can I do that? Alternatively (again, since I do not have a lot of information about this database), it could be that I have been given the incorrect SID for this database.

Thanks,
Eric
Re: Able to connect via SERVICE_NAME, but not SID [message #192254 is a reply to message #192116] Mon, 11 September 2006 10:12 Go to previous message
email.sandeepnaik
Messages: 121
Registered: August 2006
Senior Member
you have "global_names" set to true and sqlnet.ora with WORLD as default domain.

Comment out entry for default domain from sqlnet.ora

Sandeep
Previous Topic: Accessing Oracle Database behing Firewall via DB-link
Next Topic: ODBC driver not responding - please help
Goto Forum:
  


Current Time: Sun Apr 28 19:37:23 CDT 2024