RE: Use of OID for name resolution

From: Bobak, Mark <>
Date: Thu, 22 Oct 2009 16:38:35 -0400
Message-ID: <>

Wow! I didn't know you could do that!

Very cool! (Learn something new every day!)

And yes, I just tested, and it works.

[oracle_at_fv360eval201 ~]$ tnsping prd1

TNS Ping Utility for Linux: Version - Production on 22-OCT-2009 16:35:15

Copyright (c) 1997, 2009, Oracle. All rights reserved.

Used parameter files:

Used LDAP adapter to resolve the alias
[oracle_at_fv360eval201 ~]$ cat $ORACLE_HOME/network/admin/ldap.ora # LDAP.ORA Network Configuration File: /oracle/product/9.2.0/network/admin/ldap.ora # Generated by Oracle configuration tools.

DEFAULT_ADMIN_CONTEXT = "" DIRECTORY_SERVERS= (dtgoid.aa1.pqe:3838) <<========== This is my tnsManager server!

DIRECTORY_SERVER_TYPE = OID [oracle_at_fv360eval201 ~]$ sqlplus system

SQL*Plus: Release Production on Thu Oct 22 16:35:44 2009

Copyright (c) 1982, 2009, Oracle. All rights reserved.

Enter password:

Connected to:
Oracle Database 11g Enterprise Edition Release - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options

Session altered.

SYSTEM_at_xmldb64> select db_link from dba_db_links;

no rows selected

SYSTEM_at_xmldb64> select * from dual_at_prd1;


So, yes, it works. I guess it makes sense. I don't think Oracle knows the difference between a real OID server and a tnsManager server.


-----Original Message-----
From: Yong Huang [] Sent: Thursday, October 22, 2009 4:28 PM To: Bobak, Mark
Subject: RE: Use of OID for name resolution

> Check out tnsManager, here:


Do you know if tnsManager has the capability of resolving a connection for your SQL that references a remote connection without a DB link? What I mean is that, with OID (or NAMES), "select * from t_at_conn" works even without creating the database link "conn", as long as

  • "conn" is a connection string entry in OID that resolves to a remote database
  • The DB server you run the query on is configured to look up names in OID
  • The username/password are the same for this local and the "conn" database (if not, you get ORA-1017, but not ORA-02019: connection description for remote database not found)

I find this feature quite convenient when I need to access a remote database on a temporary, or even permanent, basis.

Yong Huang       

Received on Thu Oct 22 2009 - 15:38:35 CDT

Original text of this message