OS : Microsoft Server 2008 R2 (x64)
Oracle Version : 11g XE (x32)
Database name : XE
I've been fighting over with providers for a whole day and I can't seem to make this work out,
I have an application(Web, on a IIS 7) that connects to a schema, the connection uses a Oracle Provider For OleDB, well at first I was getting a "Provider not registered" error, that was easy I only had to make the app run on x32 and puf the error changed, so I quickly set up the Data Source ( with the data source manager located in WOW64 ) with a oracle ole db provider, no problems, I can click on it, it will ask me for a user/password and when I click test connection I works just like I would expect it to work, now back to the application, when i set the connection string up, I get a error from the app : ORA-12154 TNS:could not resolve the connect identifier specified. So went up and tried making a udl ( invoking again the x32 ), same error ORA-12154 so I started digging and so far so good what I got is, "try tnsping <instance_Name>", did it, and got an OK (40ms) (though I had to navigate to bin folder, which was not explained in the posts, perhaps this means something ?) and also registered the oraoledb11.dll with regsvr32
Oh ! And I can connect to the database with sqldeveloper
I know really little of Oracle, any thoughts ?
ORA-12154 ALWAYS only occurs on SQL Client & no SQL*Net packets ever leave client system
ORA-12154 NEVER involves the listener, the database itself or anything on the DB Server.
ORA-12154 occurs when client requests a connection to some DB server system using some connection string.
TNS-03505 is thrown by tnsping & is same error as ORA-12154 thrown by sqlplus or others.
The lookup operation fails because the name provided can NOT be resolved to any remote DB.
The analogous operation would be when you wanted to call somebody, but could not find their name in any phonebook.
The most frequent cause for the ORA-12154 error is when the connection alias can not be found in tnsnames.ora.
The lookup operation of the alias can be impacted by the contents of the sqlnet.ora file; specifically DOMAIN entry.
So post the content of the sqlnet.ora file.
TROUBLESHOOTING GUIDE: ORA-12154 & TNS-12154 TNS:could not resolve service name [ID 114085.1]
Here's what I have in my sqlnet.ora, please noticed, the names.directory was something I read on a post and tried when already having this problem.
I just don't understand how come the data source connection test works out.
# This file is actually generated by netca. But if customers choose to
# install "Software Only", this file wont exist and without the native
# authentication, they will not be able to connect to the database on NT.
names.directory_path = (TNSNAMES,ONAMES,HOSTNAME)
SQLNET.AUTHENTICATION_SERVICES = (NTS)