EF 4.3 Beta1—released yesterday—integrates Code First Migrations into the EntityFramework NuGet package. Part of this integration means that databases created with Code First no longer include the EdmMetadata table. The databases are instead setup to work directly with Migrations making it easy to migrate the database in the future even if this need is not anticipated when the database is first created. But what exactly happens behind the scenes? And what is the update experience for databases that already contain EdmMetadata? This post goes into some detail to answer these questions.
This is one of those posts that may only be useful for a short time since we already have a group of people working on migrations support for Code First. That being said I’ve been asked twice in the corridors of Building 18 recently how to manually create the model hash that Code First stores in the EdmMetadata table so I thought a few words about that strange EdmMetadata thing might be generally useful.