Search code examples
c#asp.net-core.net-coreentity-framework-coreedmx

Why .edmx auto generation no longer in .net core


I just noticed new Entity Framework Core does not provide .edmx generation any more. But I was loving this because it helps me to focus on application logic, not always create class and do migration things to update database. Now my question is- Does Microsoft have any future plan to add .edmx on Entity Framework Core? Or its permanently gone from .Entity Framework Core? I searched over internet but didn’t found any good answer for that.


Solution

  • Edmx is not there in Entity Framework Core. It only supports a code-first approach. It produces entity class files instead of an edmx file. You can use dotnet ef dbcontext scaffold, it scaffolds a DbContext and entity types for a database.

    You can refer the document to start with the already existing database. https://learn.microsoft.com/en-us/ef/core/get-started/aspnetcore/existing-db