0

I can connect to remote Oracle db using Oracle SQL Developer after tuning TNSNAMES.ora. I can also connect to remote Oracle db using export import vizard in SQL server. When do tnsping sourcename on command prompt, I get the correct response. This shows my TNSNAMES is correct.

But when I try to add datasource in Visual Studio 2010 under server explorer, it gives me ORA-12154!!

Based on a couple of suggestions in forums, I added the below line to sqlnet.ora

NAMES.DIRECTORY_PATH= (LDAP, TNSNAMES, HOSTNAME) 

but I still get the same error!

The Oracle Data Access Components (ODAC) 11.2.0.3 is installed.

Kevin
  • 53,822
  • 15
  • 101
  • 132
user219628
  • 3,755
  • 8
  • 35
  • 37

1 Answers1

0

The problem is your TNS. Check these three solutions :

Make sure that "TNSNAMES" is listed as one of the values of the NAMES.DIRECTORY_PATH parameter in the Oracle Net profile (SQLNET.ORA)

Verify that a TNSNAMES.ORA file exists and is in the proper directory and is accessible.

Check that the net service name used as the connect identifier exists in the TNSNAMES.ORA file.

Doctor
  • 178
  • 1
  • 3
  • 14