Understanding Migrations

Before going ahead, it would be useful to say a few words explaining what Code-First Migrations actually are and the advantages we gain by using them.

Whenever we’re developing an application and defining a Data Model, we can be sure that it will change a number of times for many good reasons: new requirements from the product owner, optimization processes, consolidation phases, and so on. A bunch of properties will be added, deleted, or have their type changed. Chances are, sooner or later, we’ll be adding new entities as well, and/or changing their relation pattern according to our ever-changing needs.

Each time we do something like that, we’ll also put our Data Model out of sync with its underlying, Code-First ...

Get ASP.NET Core 2 and Angular 5 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.