December 4, 2024

EF Core 9.0: UseSeeding and UseAsyncSeeding

EF Core 9.0 (EF 9) introduced new methods UseSeeding and UseAsyncSeeding to seed the initial data. Let’s have a look at an example. Consider the following MyDbContext. public record Blog{    public int Id { get; set; }     public string Name { get; set;&nbsp