Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
401 views
in Technique[技术] by (71.8m points)

odp.net - What is the minimal setup required to deploy a .NET application with Oracle client 11?

What is the minimal setup required to be able to deploy a .NET application that talks to an Oracle database?

question from:https://stackoverflow.com/questions/923283/what-is-the-minimal-setup-required-to-deploy-a-net-application-with-oracle-clie

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Josh-

Thank you very much for taking the time to answer. Your instructions helped a whole lot, and are very close to what I have found on my own.

Interestingly enough, I found it can be slimmed a little more.

For those in my situation who

  1. Do not want their users to have to install ODAC or the full-size Oracle Client
  2. Do not care about the re-usability of the particular client installtion
  3. Need a "clickOnce" compatible solution

I found a way to do that.

a. Download the "Oracle Instant Client 11.1.0.6 - Basic Lite". b. unzip to any folder and copy the following files to your Visual Studio project root:

  • oci.dll
  • ociw32.dll
  • orannzsbb11.dll
  • oraocci11.dll
  • oraociicus11.dll
  • msvcr71.dll (not necessary, should be supplied with most Windows versions)

    (the first five are the minimum needed for the Oracle Instant Client, the last is the microsoft common runtime they use.)

c. Download the ODAC 11 XCopy (the current version is 11.1.0.6) and unzip.

  • OraOps11w.dll - in the odp.net20 folder, goes in your project root.

    (this file is what the Oracle.DataAccess.dll talks to and uses to work with the Instant Client files).

d. For compatibility with ClickOnce deployment, select these files in your project and make sure they are "Content" and "Copy Local" in your project. The manifest will then deploy them properly.

Result... the payload added to your project is 30mb, which kinda sucks, but much better than 100+ or 400+, supports western characters, but kicks butt in that

  1. it requires no path,
  2. requires no registry entries,
  3. is isolated in deployment and does not hose other Oracle Client installations,
  4. works will all DBs back through 9.2.

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...