ODP.NET Configuration in Web.config

13,414

Solution 1

ODP 9.2 was released before .Net 2, and does not implement the new interfaces and factories this framework added (in the System.Data.Common namespace)

In other words, you cannot configure this version of ODP via the System.Data.Common configuration entries. ADO.net 2.0 compatibility started with version 10.2.0.2 of ODP (see http://www.oracle.com/technology/oramag/oracle/06-winsupp/win06odp.html for instance)

Solution 2

check also the Oracle® Data Provider for .NET Developer's Guide

Edit:

OK, so I guess this is what you are looking for:

Add under <configuration> <configsections> the following entries to web.config:

<section name="oracle.dataaccess.client" 
type="System.Data.Common.DbProviderConfigurationHandler, System.Data, 
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />

Add under <system.data> <DbProviderFactories> the following entry

<add name="Oracle Data Provider for .NET" 
invariant="Oracle.DataAccess.Client" description="Oracle Data Provider 
for .NET" type="Oracle.DataAccess.Client.OracleClientFactory, 
Oracle.DataAccess, Version=2.102.2.20, Culture=neutral, 
PublicKeyToken=89b483f429c47342" />
Share:
13,414
Guille
Author by

Guille

Updated on June 25, 2022

Comments

  • Guille
    Guille almost 2 years

    I'm adding the odp configuration in the application web.config file. For this I have a configuration section named "oracle.dataaccess.client". Therefore I'm adding an entry in the <configSections> section. Something like this:

    <section name="oracle.dataaccess.client" type="System.Data.Common.DbProviderConfigurationHandler, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
    

    I'm not sure about the type parameter. My question is, what value must i use for the type parameter? Where can I find it? The Oracle client is 9.2. The .net framework is 1.1

  • Guille
    Guille over 15 years
    I've already checked that link. The information is not in the guide
  • Tikhon
    Tikhon over 7 years
    Dead link above