EF Core column name from mapping api
问题 In EF 6.1 the mapping API was introduced where we could finally get access to table names and column names. Getting the table name is a very nice change in EF Core, but I have not yet uncovered how to get the column names. For anyone interested here is how I got the table name in the latest version (RC1) context.Model.FindEntityType(typeof(T)).SqlServer().TableName What is the current method to get column names or is this not available yet? 回答1: var columnNames = ctx.Model.FindEntityType