-
-
Save christiannagel/6b6f9fd8d243e9790392b5ec68c72968 to your computer and use it in GitHub Desktop.
Applying migrations with EF Core
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static void SeedWithMigrations() | |
{ | |
using (var context = new F1Context()) | |
{ | |
context.Database.Migrate(); | |
Console.WriteLine("F1 database created, seeded, and updated"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment