Code fisrt update comments to MySQL database

Source: Internet
Author: User

Background:

From a Java project to a. NET core project, convert Java entities to. NET entities, and then update directly to the database using the EF tool

The command is as follows:

Enable-migrations-enableautomaticmigrationsadd-migration Initialcreateupdate-database-verbose Update will encounter a few issues 1. Foreign key relationship: Because my project uses GUIDs to do associations, all do not use foreign keys, if you want to do foreign key Association can refer to this article https://www.cnblogs.com/xishuai/p/ Ef-dbcontext-savechanges-foreignkey-value.html 2. Comments cannot be updated to the database if a comment is manually added to the database, dozens of tables, will be very painful: and then look at the online ideas, based on the generated XML to get comments , update to the database if you have any tools, I hope you share the next-,-, the following simple introduction:

Code fisrt update comments to MySQL database

Related Article

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.