oracle官方的托管驱动,发布只需一个6M多的dll,支持EF 支持分布式事务,使用步骤如下:

1,Download ODP.NET, Managed Driver .zip file to a directory for staging the install.
2,Unzip the download to expand its contents into the target directory.
3,Run configure.bat to GAC and configure machine.config for ODP.NET, Managed Driver.
4,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.*).

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的更多相关文章

  1. ORACLE官方全托管驱动 Oracle.ManagedDataAccess 12.1.0.1.0

    以前用Oracle的时候,必须得装他臃肿的客户端,网上虽然也有提供直连Oracle的驱动,但也是要收费的,最近Oracle终于开窍了,提供了官方的全托管驱动. 这次是随Oracle ODAC 12c  ...

  2. Oracle官方非托管Odac驱动与Oracle官方托管odac驱动

    方便自己,方便他人,记一次连接oracle的经历,使用 [Oracle官方非托管Odac驱动,Oracle.DataAccess.Client]连接数据库的时候程序会报错,找了很久都不知道是什么原因, ...

  3. Oracle JDBC:驱动版本区别与区分 [转]

    classes12.jar,ojdbc14.jar,ojdbc5.jar和ojdbc6.jar的区别,之间的差异 在使用Oracle JDBC驱动时,有些问题你是不是通过替换不同版本的Oracle  ...

  4. [Java] Oracle的JDBC驱动的版本说明

    classes12.jar,ojdbc14.jar,ojdbc5.jar和ojdbc6.jar的区别,之间的差异 作者:赵磊 博客:http://elf8848.iteye.com 来源:http:/ ...

  5. Oracle全表扫描

    优化器在形成执行计划时需要做的一个重要选择——如何从数据库查询出需要的数据.对于SQL语句存取的任何表中的任何行,可能存在许多存取路径(存取方法),通过它们可以定位和查询出需要的数据.优化器选择其中自 ...

  6. Oracle 11g Java驱动包ojdbc6.jar安装到maven库,并查看jar具体版本号

    ojdbc6.jar下载 Oracle官方宣布的Oracle数据库11g的驱动jar包是ojdbc6.jar ojdbc6.jar下载地址:https://www.oracle.com/technet ...

  7. Qt 中 Oracle 数据库 QOCI 驱动问题及解决

    Qt 中 Oracle 数据库 QOCI 驱动问题及解决是本文要讲述的问题,用Qt开发Oracle程序时,常会遇到QOCI驱动问题,主要表现为程序运行时出现下面的错误. QOCI driver not ...

  8. Win7安装Oracle Instantclient ODBC驱动 后配置DSN时出错的解决办法 SQORAS32

    安装过程简述 oracle官网下载了 instantclient-odbc-nt--.zip instantclient-basic-nt-.zip 我这是32位版的win7,按照需要下载对应的版本. ...

  9. [Oracle]使用InstantClient访问Oracle数据库

    环境 操作系统: Win8.1 Enterprise Oracle开发工具: PL/SQL Developer 7.0.1.1066 (MBCS) 步骤 下载InstantClient Oracle官 ...

随机推荐

  1. javascript 布局 第20节

    <html> <head> <title>页面布局</title> <style type="text/css"> bo ...

  2. Ubuntu系统的安装

    在上一篇博客中,我们已经建立了一个“空白”的虚拟Ubuntu镜像,在这篇博客中,我们将介绍如何安装并进入完整的Ubuntu系统. 写在前面:不同版本的系统在安装过程中,有些操作可能会不同,但是其核心步 ...

  3. STL unique使用问题

    string strs[] = {"one","one","two","three","three" ...

  4. Linux命令——监视相关

    1.netstat 用于显示各种网络相关信息,如网络连接,路由表,接口状态 (Interface Statistics),masquerade 连接,多播成员 (Multicast Membershi ...

  5. Entity SQL 初入

    Entity SQL 是 ADO.NET 实体框架 提供的 SQL 类语言,用于支持 实体数据模型 (EDM).Entity SQL 可用于对象查询和使用 EntityClient 提供程序执行的查询 ...

  6. leetcode problem 6 ZigZag Conversion

    The string "PAYPALISHIRING" is written in a zigzag pattern on a given number of rows like ...

  7. jquery tab mouseover 特效

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/ ...

  8. php随机生成福彩双色球号码

    发布:thebaby   来源:net     [大 中 小] 不瞒您说,俺也是个双色球爱好者,经常买,但迟迟没有中过一等奖,哈哈.这里为大家介绍用php随机生成福彩双色球号码的二种方法,供朋友们学习 ...

  9. java 各种排序算法

    各种排序算法的分析及java实现   排序一直以来都是让我很头疼的事,以前上<数据结构>打酱油去了,整个学期下来才勉强能写出个冒泡排序.由于下半年要准备工作了,也知道排序算法的重要性(据说 ...

  10. Python Tips and Traps(一)

    1.如果想得到一个列表的index和内容,可以通过enumerate快速实现 drinks = ['coffee','tea', 'milk', 'water'] for index, drink i ...