I'm using the oracle.dataaccess.dll when having to query an Oracle DB. But it doesn't work if the user doesn't have an Oracle client installed on his machine. Is it possible to somehow include the Oracle client inside a dll so the user won't have to explicitly install the client?
-
Well, sometimes you can embed it or merge it, but usually you can just ship the library dll with your project - does that not suffice?Marc Gravell– Marc Gravell2013-04-10 11:20:42 +00:00Commented Apr 10, 2013 at 11:20
-
@MarcGravell: Unfortunatelly, it doesn't suffice with Oracle.Daniel Hilgarth– Daniel Hilgarth2013-04-10 11:22:43 +00:00Commented Apr 10, 2013 at 11:22
4 Answers
The managed ODP.net client is exactly what you want. Now that there's a 12c version out, it's a simple single assembly that you can deploy with your application and not have to worry about Oracle installations.
There's also a nuget package that you can use if you don't want to install on your system. That is very painless to get up and running. Here's some links to those:
1 Comment
You can ship the Oracle Instant Client with your application.
This is a complete Oracle client but it doesn't require installation, it can be used directly.
However, you need to be aware of the following:
- The instant client is over 120 MB in size.
- You need different versions of the instant client for x86 and x64, bringing the size to about 250 MB.
The advantage of using the instant client is that you don't have to worry about the installed version of the Oracle client. Even if the computer already has an incompatible version installed, your application will work, because it comes with the correct version.
If you're able to pay, I've had fair success with DevArt's DotConnect for Oracle as an alternative to the client provided by Oracle.
It provides a completely managed way of connecting to and querying Oracle, along with Entity framework & nHibernate support and emulation for GUIDs, booleans and a few other datatypes where Oracle lacks support (GUID is raw(16) in Oracle).
All you have to do is ship a single managed DLL with your project.
5 Comments
Oracle.DataAccess.Client is in .Net4. I hadn't heard of System.Data.OracleClient, is it packaged with .Net?