Automated SQL scripts using Entity Framework Core migrations

You can use Entity Framework Core migrations to automate SQL commands across all environments.

You can learn more about using migrations in EF Core, or watch the video:

Download the code example

You'll need to fill out the code example form. We will send you an email where you can download the code example.

Software

This is the software that will need to be installed onto your machine.

The application

Inside RunMigrations/appsettings.Development.json, find ConnectionStringsEFMigrationsDbContext and point the connection string to where you want your database to be created.

Open up RoundTheCode.EFCoreMigrations.slnx, and run the RunMigrations worker project. If the connection string is set up correctly, the worker project should create the database and run all the migrations inside the Migrations folder in the Infrastructure project.