zoukankan      html  css  js  c++  java
  • .NET安装和配置Oracle数据访问组件(ODAC)

    Many ASP.NET applications access Oracle database for the data source. Oracle supports the .NET with its Oracle Data Access Components (ODAC). By using ODAC, you do not have to install a heavy Oracle client in the Windows server machines which have IIS for the ASP.NET applications.

    ODAC includes Oracle Instant Client, Oracle Providers for ASP.NET, and Oracle Data Provider for .NET. Oracle Instant Client is necessary since it has Oracle’s database APIs - OCI libraries for an Oracle database client in Windows systems to connect Oracle database server. Oracle Providers for ASP.NET, and Oracle Data Provider for .NET. are required to install if you are using Oracle providers in your ASP.NET or .NET applications.

    If you using the .NET Framework Data Provider for Oracle which is in the System.Data.OracleClient namespace (The assembly System.Data.OracleClient.dll included in the .NET frameworks), you do not need to install Oracle Providers for ASP.NET, or Oracle Data Provider for .NET. For more information about System.Data.OracleClient namespace, see Oracle and ADO.NET on MSDN.

    Let’s start the installation and configuration.

    1. Download the latest version ODAC112030Xcopy_32bit.zip orODAC112030Xcopy_x64.zip zip file from Oracle web site and unzip the .zip file in a local folder in Windows.
    For 32-bit: C: empODAC112030Xcopy_32bit
    For 64-bit: C: empODAC112030Xcopy_x64

    2. You can install either 32-bit ODAC or 64-bit ODAC, or both. Open a Command Prompt with the Administrator privilege, go to the folder above, type and run the installation script:
    For 32-bit:
    C: empODAC112030Xcopy_32bit>install.bat basic c:oracleodac32 odac32 false
    For 64-bit:
    C: empODAC112030Xcopy_x64>install.bat basic c:oracleodac odac false
    This will install the Oracle Instant Client into the folder c:oracleodac32 orc:oracleodac. Notice “Oracle Home Name” in the installation script parameters:odac32(for 32bit) or odac(for x64). Oracle Home Name has to be different if you want to install both 32-bit and 64-bit ODAC.

    3. This step is to install Oracle providers. If you only use the .NET Framework Data Provider for Oracle, you can skip this step.
    To install ODP, in the same Command Prompt, type and run installation script:
    For 32-bit Oracle Data Provider for .NET 4:
    C: empODAC112030Xcopy_32bit>install.bat odp.net4 c:oracleodac32 odac32 false
    For 64-bit Oracle Data Provider for .NET 4:
    C: empODAC112030Xcopy_x64>>install.bat odp.net4 c:oracleodac odac false

    To install ASP.NET Provider, in the same Command Prompt, type and run installation script:
    For 32-bit Oracle Provider for ASP.NET 4:
    C: empODAC112030Xcopy_32bit>>install.bat asp.net4 c:oracleodac32 odac32 false
    For 64-bit Oracle Provider for ASP.NET 4:
    C: empODAC112030Xcopy_x64>>install.bat asp.net4 c:oracleodac odac false

    4. Setup PATH System Environment Variable for IIS Windows web server. Since ODAC communicates Oracle database through OCI in the Oracle Instant Client, and OCI libraries are the native Windows librarys, you have to tell IIS where to load those libraries. Add the path of c:oracleodac32 or c:oracleodac into the PATH System Environment Variable.
    After set PATH System Environment Variable, reboot machine to make the System Environment Variable effective.

    转载自:http://www.simongong.com/blogs/?p=11

  • 相关阅读:
    Java路径问题终于解决方式—可定位全部资源的相对路径寻址
    易学设计模式看书笔记(2)
    js算法:分治法-棋盘覆盖
    [NIO]dawn之Task具体解释
    C#高级编程五十八天----并行集合
    [Swift通天遁地]九、拔剑吧-(12)创建Preview-Transition图像预览界面
    [Swift通天遁地]九、拔剑吧-(11)创建强大的Pinterest风格的瀑布流界面
    [Swift通天遁地]九、拔剑吧-(10)快速创建美观的聊天界面:可发送文字、表情、图片
    [Swift通天遁地]九、拔剑吧-(9)创建支持缩放、移动、裁切的相机视图控制器
    [Swift通天遁地]九、拔剑吧-(8)创建气泡式页面切换效果
  • 原文地址:https://www.cnblogs.com/jmax/p/3151944.html
Copyright © 2011-2022 走看看