How to Codefirst programming

Source: Internet
Author: User

Step One: Create a console project
Step Two: Add New project →ado.net empty entity model
Step Three: Add Entities: Customer, add a few required test fields
Fourth step: Add a link between entities
Fifth step: Generate database Script from model and execute SQL script to create database
Sixth step: Write additions and deletions to explain the basic use of EF

Codefirst is a technical means of entityframework, because the traditional programming method is to set up the database first, then according to the database model for the application modeling, and then development; Codefirst is literally the code First establish the entity structure in the program to map to the database, and then entityframework can generate the corresponding database based on the entity structure.

How to Codefirst programming

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.