I have to get a legacy application that uses unmanaged ODP.NET
working on a 64-bit
machine.
- I have installed
64-bit
unmanaged ODP.NET
- I have verified that the
64-bit
unmanaged ODP.NET
is working fine by testing it in a console application - I created a test web application with the same data access code as the working console application and a reference to the same
Oracle.Data.Access
DLL in theGAC
that the console application uses. The web application is unable to connect to the database. The code snippet isn't relevant, as the code works and is very simple (see point 2.).
It fails at conn.Open();
Exception.Message
is empty.
Exception.StackTrace
is not useful:
at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode,
OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object
src, String procedure, Boolean bCheck, Int32 isRecoverable) at
Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode,
OracleConnection conn, IntPtr opsErrCtx, Object src) at
Oracle.DataAccess.Client.OracleConnection.Open() at
TestODPNet.ODPNetTester.Test() in
D:\Projects\TestODPNet\TestODPNet\ODPNetTester.cs:line 27
The application is running on Local IIS
, not IIS Express
.
In IIS
, "Enable 32-bit applications
" is set to false
.
The application is targeting x64-bit
platform, not Any CPU
.
Locally, I'm using 64-bit Windows 10
and on the server, I'm using 64-bit Windows Server 2012
. I'm not able to get unmanaged ODP.NET
working on either. So, it doesn't seem like this has to do with 32-bit
binaries as far as I can tell since ODP.NET
and both OSes are all 64-bit
.
Edit: The application pool is (temporarily for a test) running using the same account as the console application, which is administrator on the machine.
What am I missing? How can I get unmanaged ODP.NET (64-bit)
working in ASP.NET
on 64-bit
O/S?
Note: This question looks a bit similar to other questions, but it is not as far as I can tell
Note 2: Yes, I know that the recommended way is to use managed ODP.NET
, but I do not have the source code and thus cannot make that change.