private static void PrintEFCoreMappings() { Console.WriteLine("EF Core Mappings"); using (var db = new EFCore.BloggingContext()) { // TODO Print type to table mappings } }
private static void PrintEFCoreMappings() { Console.WriteLine("EF Core Mappings"); using (var db = new EFCore.BloggingContext()) { foreach (var entity in db.Model.GetEntityTypes()) { Console.WriteLine($" {entity.ClrType.Name} => {entity.SqlServer().TableName}"); } } }