Entity Framework Collection

Source: Internet
Author: User

Entity Framework - Data Persistence framework: Entity FrameWork

  1. Program through{Object Relational Mapping:ORM(Object Relational Mapping):created a "virtual object database" that can be used in a programming language}interacting with the Entity Framework, the Entity FrameworkADO Provider (Direct provider: SQL Server, Oracle,Indirect provider: OLE DB, ODBC)To interact with the database.

    1. Entity Framework creation, right-click Add New item in existing project in existing solution

Tim In addition, we get the edmx file ( edmx edmx file, we can know edmx xml file, we fold the node to get:

    1. folding through the nodes, we get edmx The overall architecture:

<edmx:Runtime> relationships to automatically generate CS code for entity classes, mappings, attributes, and more , expand edmx : Runtime,

<!--SSDL content--> the next is the physical model

<!--CSDL content--> the next is the conceptual model

The physical model and the conceptual model contain the same content, and the unique schema node consists of 3 parts, namely the entity container EntityContainer, the entity type EntityType (each entity generates one such node), Relationship Association (each foreign key relationship for a database generates one such node)

<!--c-s mapping content-->

mapping refers to the mapping of a physical model to a conceptual model , entity attribute corresponds to column name one by one

View the solution edmx the node also exists to TT The database context file for the extension, which exists under entities , all of our subsequent additions and deletions to entities are encapsulated in this class.

The Entity Framework is created in two forms, one is to get the Entity Framework from the database, the other is to get the database from the Entity Framework, and we can choose according to the actual situation.

Entity Framework Collection

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.