专注收集记录技术开发学习笔记、技术难点、解决方案
网站信息搜索 >> 请输入关键词:
您当前的位置: 首页 > LINQ

odac Entity Framework连接oracle,该怎么处理

发布时间:2011-06-24 21:54:19 文章来源:www.iduyao.cn 采编人员:星星草
odac Entity Framework连接oracle
以ObjectContext+LINQ方式在控制台应用程序中,使用odac连接oracle数据库,代码如下:

string city = "London";
using (Entities entities = new Entities())
{
  var query = from c in entities.Customerswhere c.Address.City == cityselect c;
  foreach (Customers c in query) 
  Console.WriteLine(c.CompanyName);
}

其中用到的命名空间有:
using System.Data;
using System.Data.Entity;
using System.Data.EntityClient;
using System.Data.Common;
using System.Data.EntityModel;
using Oracle.DataAccess.Client;

但是我在web开发中,和控制台中的设置完全相同,当写到Entities entities = new Entities()时,
发现没有程序集的引用,在网上搜了半天都没解决,希望各位大神给小弟指点迷津,感谢不尽!!!

------解决方案--------------------
添加项目引用了木有
友情提示:
信息收集于互联网,如果您发现错误或造成侵权,请及时通知本站更正或删除,具体联系方式见页面底部联系我们,谢谢。

其他相似内容:

热门推荐: