-
Notifications
You must be signed in to change notification settings - Fork 18
Insight.Database.Schema v EF Code Migrations
So what's the difference between Insight.Database.Schema and EF Code Migrations (EFCM)?
Insight: managing upgrades since 2003.
EFCM: new.
Insight: manage your SQL as SQL. (Even let your DBA look at it.)
EFCM: C# tables, plus some model building syntax that autogenerates SQL.
Insight: just modify your SQL and run the installer.
EFCM: modify your objects, then run some scripts that generates migration code, then track the proper order.
Insight: undo your change and run the installer.
ECFM: you can the migrator to run back to old versions.
Insight: use the ScriptChanges method.
ECFM: you can run the migrator with source and target versions and output a script.
Insight: use the installer on its own, or combine it with [Insight.Database], or use another ORM.
ECFM: tied to using EF for your ORM (unless you jump through some hoops).
Insight: works well with SQL things like service broker, partitions, security, etc.
ECFM: not so much. Unless there are some hidden C# attributes I haven't seen yet.