Re: "ORA-12154: TNS:could not resolve service name" with Oracle Data Provider for .NET

From: Chris <newsgroup.replies_at_netchris.com>
Date: 6 Jan 2004 07:18:02 -0800
Message-ID: <20094607.0401060718.70d4a4f7_at_posting.google.com>


newsgroup.replies_at_netchris.com (Chris) wrote in message news:<20094607.0401051455.287c7e57_at_posting.google.com>...
> I have installed Oracle Data Provider for .NET (9.2.0.4.0) and am
> trying to make a simple connection to a database. I can test connect
> fine with the Net Manager and have verified that my TNSNames.ora and
> SQLNET.ora files are non-duplicated. I am assuming that they are
> correct as I saved my configuration in Net Manager after testing the
> connection successfully.
>
> However, when attempting to connect from C#, I get an excpetion with
> the error:
> "ORA-12154: TNS:could not resolve service name"
>
> Same thing happens also when trying to use
> System.Data.OleDb.OleDbConnection as well.
>
> Can anyone steer me in the right direction of where to look first?

Looks like I can't get anything programmatic to hook up. I can test fine from NetManager and from testing a DSN in ODBC Data Sources (DSN). However, when I try to access the data source from C#, I am always getting 12154. This is with OdbcConnection, OleDbConnection, and OracleConnection. All of them. I'm stumped. Received on Tue Jan 06 2004 - 16:18:02 CET

Original text of this message