Migration from Entity Framework 4.1/4.3 to Entity Framework 5.0/6.0

To migrate your existing Entity Framework 4.x project to Entity Framework 5.0 using VS2012, first target .NET Framework 4.5:

Second, remove the existing Entity Framework 4.1/4.3 reference and install Entity Framework 5.0 from NuGet:

Search for Entity Framework online and install it. Make sure that the version is 5.0:

If you check the version of the Entity Framework reference, then it should be 5.0.0.0:

If you open your existing data model (.edmx) file then it may give an error, as it is still using EDMX version 2.0 (open edmx as XML). Click on the 'Modify' link on the designer and it will be modified to version 3.0.

Now your existing Entity Framework project will work in Entity Framework 5.0 without any major changes.

Entity Framework Tutorial Basics(31):Migration from EF 4.X的更多相关文章

  1. Entity Framework Tutorial Basics(1):Introduction

    以下系列文章为Entity Framework Turial Basics系列 http://www.entityframeworktutorial.net/EntityFramework5/enti ...

  2. Entity Framework Tutorial Basics(4):Setup Entity Framework Environment

    Setup Entity Framework Environment: Entity Framework 5.0 API was distributed in two places, in NuGet ...

  3. Entity Framework Tutorial Basics(43):Download Sample Project

    Download Sample Project: Download sample project for basic Entity Framework tutorials. Sample projec ...

  4. Entity Framework Tutorial Basics(42):Colored Entity

    Colored Entity in Entity Framework 5.0 You can change the color of an entity in the designer so that ...

  5. Entity Framework Tutorial Basics(41):Multiple Diagrams

    Multiple Diagrams in Entity Framework 5.0 Visual Studio 2012 provides a facility to split the design ...

  6. Entity Framework Tutorial Basics(37):Lazy Loading

    Lazy Loading: One of the important functions of Entity Framework is lazy loading. Lazy loading means ...

  7. Entity Framework Tutorial Basics(36):Eager Loading

    Eager Loading: Eager loading is the process whereby a query for one type of entity also loads relate ...

  8. Entity Framework Tutorial Basics(34):Table-Valued Function

    Table-Valued Function in Entity Framework 5.0 Entity Framework 5.0 supports Table-valued functions o ...

  9. Entity Framework Tutorial Basics(33):Spatial Data type support in Entity Framework 5.0

    Spatial Data type support in Entity Framework 5.0 MS SQL Server 2008 introduced two spatial data typ ...

随机推荐

  1. PhotoShop使用指南(2)——下雨动画效果

    第一步: 第二步: 第三步: 第四步:

  2. STL空间配置器解析和实现

    STL空间配置器的强大和借鉴作用不言而喻,查阅资料,发现了Dawn_sf已经对其有了极其深入和详细的描述,所以决定偷下懒借用其内容,只提供自己实现STL空间配置器的源码,具体解析内容参考:(一)STL ...

  3. 使用virtualenv搭建python3的环境

    转:http://blog.csdn.net/liuchunming033/article/details/46008301 转:http://www.jb51.net/article/85527.h ...

  4. C的随想

    c用的是操作系统函数,这个一下子就限制了APi的数量,通过组合这些系统api即可实现功能. c开发的人一般都会熟记系统函数,然后需要确定函数参数的时候,通过man指令进行查看 对于32位64位将会导致 ...

  5. ECMAScript6入门-序言

    本系列笔记基于阮一峰大佬的开源书籍.如果大家想看可以去该地址 本系列笔记只记录本人自己学习的过程,如果有侵权收到通知会自行下架. 如果大家看到可以直接去地址处学习,如果觉得好还望支持正版. 在此感谢阮 ...

  6. 第二篇 Mysql常用操作记录(转载)

    我们在创建网站的时候,一般需要用到数据库.考虑到安全性,建议使用非root用户.常用命令如下: 1.新建用户 //登录MYSQL@>mysql -u root -p@>密码//创建用户my ...

  7. spark 算子分析

    别的不说先上官网: action 这些算子中需要注意: 1.reduce 和 reduceByKey 虽说都有reduce,但是一个是action级别,一个是transformation级别,速度上会 ...

  8. Mybatis Laz-Load功能实现代码赏析(原创)

    对于Mybatis 拥有的Lazy Load(有中文翻译成延迟加载)功能,应该很同学都有听说过,今天主要与大家一起来解读一下Mybatis在Lazy Load功能的实现的代码.Lazy Load实现的 ...

  9. Regexp:目录

    ylbtech-Regexp:目录 1.返回顶部 1. http://www.runoob.com/regexp/regexp-tutorial.html 2. 2.返回顶部   3.返回顶部   4 ...

  10. python第三十二天-----算法

    算法(Algorithm):一个计算过程,解决问题的方法时间复杂度:用来评估算法运行效率的一个东西ps:在日常使用中,请使用sort(),because no zuo no die! 1.冒泡排序:指 ...