ODBC Administrator Can't Find Oracle TNS Names File

pixelbobby picture pixelbobby · Jul 11, 2012 · Viewed 99.8k times · Source

With a new Oracle Installation when I go to Configuration Management Tools > Microsoft ODBC Administrator > System DSN > Add > [new installation] it does not have the TNSNAMES.ora connection name in the drop down. With the old installation, this had worked.

Create New Data Source

I've tried updating Environment Paths and Registry keys but still can't find a way to get ODBC to see it in the drop down.

enter image description here

There was a previous installation of Oracle Client on the Windows Server. I tried to remove most of the files but our Oracle DBA said we could just do another install and update the Environment Paths with the new location.

I understand there are two other posts on SO here and here regarding this issue. However, I'm not sure TNS PING will help yet because it seems to be an issue regarding Environment Paths and ODBC being able to locate the .ora file.

TNSNAMES.ORA Location

TNS_Admin = E:\app\[username]\product\11.2.0\client_1\network\admin\TNSNAMES.ora

Environment Variables

TNS_Admin = E:\app\[username]\product\11.2.0\client_1  
Path = E:\app\[username]\product\11.2.0\client_1

Registry Entries
home3 is the new installation. Should I delete the old registry key (home2)? HKLM\SOFTWARE\ORACLE\KEY_OraClient11g_home2 and \..._home3

Also, if I select "OraClient11g_home2" in the Create New Data Source screen here is what is displayed in the drop down:

enter image description here

Answer

Srinivas picture Srinivas · Jun 4, 2015

If service name doesn't show in the dropdown, directly type in the service name and see if you are able to test the connection.

enter image description here