4

I am planning to move from oracle unmanaged data access client to managed data access client. Right now I have ODP.Net installed on my machine which contains the DLL - Oracle.DataAccess.dll. But I am planning to move to oracle's recently released Managed data access client which contains the assembly Oracle.ManagedDataAccess.dll. Do I have to un-install the previously installed ODP.Net (unmanaged one) and then install the managed client? I have seen the installation instructions but I am not sure if this step will be required. Any help will be highly appreciated.

user1812749
  • 67
  • 1
  • 2

2 Answers2

5

New Oracle.ManagedDataAccess.dll is a magnificent thing. Just do this:

1. Delete existing reference to Oracle.DataAccess from your project and add a new Oracle.ManagedDataAccess.dll from the downloaded folder: odp.net\managed\common\Oracle.ManagedDataAccess.dll.
2. Set it's property Copy Local = True so it will be deployed along with your project.
3. Don't forget to add a new "using" line to your code: using Oracle.ManagedDataAccess.Client;
4. You can change the project platform target to AnyCPU now and it will work !


There's no need to install anything more, no other clients, this is some kind of oracle's packed crossplatform (64-bit and 32-bit) dll client which worked perfectly for me after all those spended hours before figuring out which dll-s (oci.dll, orannzsbb11.dll, oraociei11.dll, OraOps11w.dll) need to go in with the project for 64-bit machine and 32-bit machine fo my application to work...

Ivan Tadic
  • 143
  • 2
  • 9
  • It appears to be a good solution unless you're using Oracle's Membership/Profile/Roles, etc. providers. Those use Oracle.Web.dll, which wants to revert back to the old unmanaged Oracle.DataAccess.dll. This was a frustrating find. – jimo3 Jul 16 '14 at 22:40
0

To work with managed data access driver you just need Oracle.ManagedDataAccess.dll, no oracle client required.

So you can leave your unmanaged client installed (if you are planning yo use it), or uninstall it, it is up to you.

Alexanderius
  • 822
  • 11
  • 27