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

  • 相关阅读:
    与平面和空间打交道的计算几何
    借助水流解决问题的网络流
    计算几何算法概览
    关于while (~scanf("%d %d", &m, &n))的用法
    Minimizing maximizer(POJ 1769)
    java九九乘法表
    java替换字符串中的World为Money
    java截取字符串,第4位以后的字符串用*代替
    java使用valueOf的方法反转字符串输出
    java使用StringBuilder的方法反转字符串输出
  • 原文地址:https://www.cnblogs.com/jmax/p/3151944.html
Copyright © 2011-2022 走看看