Question : ORA-12154 error in ASP.NET page

I am fairly new to Oracle but have searched to try and resolve this problem with no luck. I have an ASP.NET page with an ODP Oracle connection object. When I call conn.Open() it fails with a ORA-12154: TNS:could not resolve the connect identifier specified. This is running on localhost, no actual separate server involved.

I have my identical tnsnames.ora and sqlnet.ora files in the following directories:
C:\Oracle\ora90\network\Admin
C:\Oracle\product\10.2.0\client_1\network\Admin

It is defined such that when I try to access my database using tnsping or sqlplus, it works perfectly fine.

With tnsping:
"Used parameter files: C:\oracle\product\10.2.0\client_1\network\admin\sqlnet.ora"
Then it resolves the alias and says "OK (10 msec)" at the bottom.

With sqlplus:
Connects fine, gives me sqlplus prompt, and access to the DB"

Any ideas what the problem is??? Thanks!

Answer : ORA-12154 error in ASP.NET page

Nothing is jumping out at me.

Did you install ODP.Net after you installed Oracle?  I'm wondering if you might have 2 Oracle Homes and ODP is pointing to one that isn't configured.
Random Solutions  
 
programming4us programming4us