locked
Will Entity Framework auto update if I change table schema? RRS feed

  • Question

  • Hi All,

    I'm new to Entity Framework. May I know will Entity Framework auto update if I change table schema (for eg: Add new column, delete column, change field datatype....) without regenerate at Visual Studio / redeploy application to client PC?

     

    I will using Entity Framework 4.1.

     

    Thank you very much.


    Monday, April 25, 2011 5:35 AM

Answers

  • No, it won't.

     

    You need to update the model and recompile your app if you change the underlying schema and want to access new columns/tables or not get errors if you drop columns/tables/etc.


     
       Cool tools for Linq-to-SQL and Entity Framework 4:
     huagati.com/dbmltools - Visual Studio add-in with loads of new features for the Entity Framework and Linq-to-SQL designers
     huagati.com/L2SProfiler - Runtime SQL query profiler for Linq-to-SQL and Entity Framework v4
    • Marked as answer by sanme98 Monday, April 25, 2011 11:42 AM
    Monday, April 25, 2011 6:05 AM