Reputation: 566
I'm running an Oracle XE 10g in a machinem i've created a test app to test some inserts, launched it in a diferent machine and everything worked fine. the problem is when I installed the large app in the same machine where oracle XE is installed. When I launch the app I get this error
Oracle.DataAccess.Client.OracleException The provider is not compatible with the version
of Oracle client
en Oracle.DataAccess.Client.OracleInit.Initialize()
en Oracle.DataAccess.Client.OracleConnection..cctor()
en Oracle.DataAccess.Client.OracleConnection..ctor()
en Test.DB.Oracle.OracleManagerConnection.GetConnection()
on this line OracleConnection conn = new OracleConnection()
I don't know how can it work from a machine and doesn't work in a different machine. The problem is in a Windows Server 2008 x64 (alredy copied the Oracle.DataAccess.dll to the .exe directory).
Upvotes: 0
Views: 6236
Reputation: 5140
There might be another case, such as running a 64bit .net run-time against a 32bit oracle client. So can you check whether the machine which host small application runs of x64 or 32bit. If it is 32bit, then obviously the copied provider will not work on X64 windows server. In such case, you either need to download 64bit provider version Or set the target CPU flag on large project ( in VS) to run in the 32bit run-time.
Upvotes: 0
Reputation: 174309
ODP.NET is a real PITA, mainly because the error message are so vague.
The following may trigger this error message:
Please be aware that the process that Oracle.DataAccess.dll uses to locate the unmanaged DLLs is pretty complicated, because it is a multi-step process that takes into account environment variables, registry values etc.
Upvotes: 1