How can we improve Entity Framework Core?

Generate database update script for Model First

I am creating a Database with the Model First SQL Script Generation. Then later when I need to Update the Model I don't want to delete all tables and content, I want to generate an update Script.

Its possible in EF4 with an Tool:
http://visualstudiogallery.msdn.microsoft.com/df3541c3-d833-4b65-b942-989e7ec74c87/

but in EF5 there is atm no possibility to update the Model with "Model first".

Idea: perhaps try to include the SQL-Schema Comparer in EF.

319 votes
Vote
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    I agree to the terms of service
    Signed in as (Sign out)
    You have left! (?) (thinking…)
    Johannes R.Johannes R. shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    16 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      I agree to the terms of service
      Signed in as (Sign out)
      Submitting...
      • Mathieu Co.Mathieu Co. commented  ·   ·  Flag as inappropriate

        The Entity Designer Database Generation Power Pack does not work on VS2012 and will probably never do. That's why i started the development of an extension that port some of the features on VS2012 :
        Generate a custom script generation workflow with the ability to choose the generation strategy (TPT or TPH) and update a database project.

        You can find it here : http://visualstudiogallery.msdn.microsoft.com/3136929a-f4dc-4ca4-a345-a0846ef04501

      • Stephen LStephen L commented  ·   ·  Flag as inappropriate

        Hopefully I'm just unaware of the new way of doing this. Otherwise it really is a shame that 2 new versions of Visual Studio have been released without addressing such a critical component.

      • Hank SchultzHank Schultz commented  ·   ·  Flag as inappropriate

        I wound up modifying the .tt and .ttinclude scripts provided with Entity Framework 5 and 6. I started with the Model First approach, which spits out the classes. I took the information about the entities that is already being built and turned the output into a valid Model First approach using the Fluent API in the OnModelCreating function. Thanks to this, I can take advantage of Code First's migrations, which is excellent. There are certain types of relationships that currently don't work, which is probably why they haven't already done it.

      • Niklas PetterssonNiklas Pettersson commented  ·   ·  Flag as inappropriate

        The entire Entity Designer Database Generation Power Pack should be at least updated to work with vs 2012. Microsoft is bigger than to blame a total abandonment of a tool on one employee...

      • OzOz commented  ·   ·  Flag as inappropriate

        its very important to have a tool to sync changes in model to db, I hope MS will add such a tool to VS

      • Anonymous commented  ·   ·  Flag as inappropriate

        Its important, that we are planning to move to EF5 from Linq2Sql eyeing the benefits of EF, If this is not fixed we can't can't do that.

      • Anonymous commented  ·   ·  Flag as inappropriate

        Really Important, especially as this was provided in VS2010, and now not in VS2012.

      • Lucas G.Lucas G. commented  ·   ·  Flag as inappropriate

        I ran into this issue today while exploring tooling for a new project. We want to use .net 4.5 + EF 5 with an existing DB. Was looking for the ability to make create updates/migrations from this approach. It also seems the tool does not support SQL Server 2012.

      Feedback and Knowledge Base