Entity Framework 6.x Introduction

 I. Introduction

  Entity Framework is an ORM framework that can be used on SQL Server, Oracle, DB2, MySQL and other databases. Its development up to now has been to 6.x version, but this version is also recommended to use the official.

 Two, Entity Framework three areas of modeling

  1、Code First

    The model is described by C # or VB.Net, and then create a database by classes referred to as the POCO (Plain Old CLR Object). POCO comes in Java POJO. The most popular field of modeling time this way. Work is also frequently used by this way, we only need to define the mapping, all the rest to the Entity Framework to deal with, including the creation of relationships between databases and tables.

  2、Model First

    Allows us to use the Entity Designer to create model entities and their relationships and inheritance hierarchies in the null model (.edmx), and then create the database, this method must select the "null model" option when you create the entity data model, rather than "from database generation "option.

  3、DataBase First

    This way we can create a database from an existing model, reducing the amount of code required to write code is automatically generated, but also limits the generated code structure we use, we have DBA data typically designed to separate development or when an existing database that already exists, it will be preferred.

Guess you like

Origin www.cnblogs.com/jesen1315/p/11013161.html