oracle全托管驱动Oracle.ManagedDataAccess
2013-01-31 15:13
89 查看
终于见到了oracle官方的托管驱动,发布只需一个6M多的dll,支持EF 支持分布式事务
附:
Download ODP.NET, Managed Driver .zip file to a directory for staging the install.
Unzip the download to expand its contents into the target directory.
Run configure.bat to GAC and configure machine.config for ODP.NET, Managed Driver.
Create a new Visual Studio 2010 console application project for C#.
Add Oracle.ManagedDataAccess.dll as a reference to the project.
Replace the contents of Program.cs with the following C# code. Notice that the namespace of ODP.NET, Managed Driver (Oracle.ManagedDataAccess.*) is different from the namespace of ODP.NET, Unmanaged Driver (Oracle.DataAccess.*).
附:
Download ODP.NET, Managed Driver .zip file to a directory for staging the install.
Unzip the download to expand its contents into the target directory.
Run configure.bat to GAC and configure machine.config for ODP.NET, Managed Driver.
Create a new Visual Studio 2010 console application project for C#.
Add Oracle.ManagedDataAccess.dll as a reference to the project.
Replace the contents of Program.cs with the following C# code. Notice that the namespace of ODP.NET, Managed Driver (Oracle.ManagedDataAccess.*) is different from the namespace of ODP.NET, Unmanaged Driver (Oracle.DataAccess.*).
// C# using System; using Oracle.ManagedDataAccess.Client; using Oracle.ManagedDataAccess.Types; namespace Connect { class Program { static void Main(string[] args) { try { // Please replace the connection string attribute settings string constr = "user id=scott;password=tiger;data source=oracle"; OracleConnection con = new OracleConnection(constr); con.Open(); Console.WriteLine("Connected to Oracle Database {0}", con.ServerVersion); con.Dispose(); Console.WriteLine("Press RETURN to exit."); Console.ReadLine(); } catch (Exception ex) { Console.WriteLine("Error : {0}", ex); } } } }
相关文章推荐
- oracle全托管驱动Oracle.ManagedDataAccess
- oracle全托管驱动Oracle.ManagedDataAccess
- ORACLE官方全托管驱动 Oracle.ManagedDataAccess 12.1.0.1.0
- PowerShell 调用 Oracle.ManagedDataAccess.dll
- VS通过Oracle驱动连接数据库,对图片进行存取操作(Oracle.DataAccess.Client.dll)
- Oracle.ManagedDataAccess.dll
- Oracle.ManagedDataAccess.dll 连接Oracle数据库不需要安装客户端
- {"未能从程序集“Oracle.ManagedDataAccess, OracleInternal.Common.ConfigBaseClass”。":"OracleInternal.Common.C
- 无法读取配置节“oracle.manageddataaccess.client”,因为它缺少节声明
- FSharp 调用 Oracle.ManagedDataAccess.dll
- Oracle.DataAccess 驱动使用因为SQL语句缓存报错问题解决办法
- C#连接Oracle数据库(直接引用dll使用-Oracle.ManagedDataAccess.dll)
- [ASP.NET]使用Oracle.ManagedDataAccess的OracleParameter参数化和OracleDataAdapter模糊查询
- Oracle.ManagedDataAccessDTC.dll加载不正确。
- Oracle.ManagedDataAccessDTC.dll 使用
- Oracle.ManagedDataAccess.dll 连接Oracle数据库不需要安装客户端
- System.Data.OracleClient 与Oracle.ManagedDataAccess.Client
- Oracle.ManagedDataAccess.dll 连接Oracle数据库不需要安装客户端
- C#连接Oracle数据库使用Oracle.ManagedDataAccess.dll
- Oracle.ManagedDataAccess.Client注意事项