0
votes

I am getting this error trying to do a test connection on an ODBC DSN with the Oracle Instant client setup on Windows 7 32 bit. I have it working on another machine with Vista 32 bit.

Info:
1. Dir Structure is: c:\oracle\instantclient_11_2. Basic client and instant client files in the instantclient_11_2 directory, just like on the working machine.
2. c:\oracle and c:\oracle\instantclient_11_2 in system path
3. Added TNS_ADMIN to system path and pointed in to c:\oracle
4. tnsnames.ora is copied from the working machine and in c:\oracle
5. sqlnet.ora is in c:\oracle. Working copy just had "TCP.CONNECT_TIMEOUT=5" as an entry but I tried adding: NAMES.DIRECTORY_PATH= (LDAP, TNSNAMES, HOSTNAME) when it wasn't working
6. I can telnet to the oracle server and the 1521 port (defined in tnsnames.ora).

Anything else to check?

2
What is the connect identifier you're using for DSN; is it a TNS alias, or an Easy Connect string, for example? Does the sqlnet.ora now match the one on the working machine? - Alex Poole
-I am just setting up a DSN in the ODBC administrator, specifying the TNS Service name in the tnsnames.ora. The sqlnet.ora is the same--as I state above the working one just has the one line. - urbanmojo
Here is the tnsnames.ora file contents, I am specifying MIADM in the DSN: ABCDM = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP) (HOST = 172.99.99.99) (PORT = 1521) ) ) (CONNECT_DATA = (SERVICE_NAME = MIADM) ) ) - urbanmojo

2 Answers

0
votes

If yout tnsnames.ora is as you said in a comment, then you're using the wrong value in your DSN. You need to use the TNS alias in the DSN, which is ABCDM. You can't refer to the service name directly, unless you happen to have used that as the alias as well.

0
votes

We have found that error to be returned when the application calling it is installed in the Program Files (x86) directory. Reinstalling the program outside that folder will clear the error. Not sure why the Oracle Instant Client won't play nice with programs installed there.