我正在使用来自DbGeography的System.Data.Entity.Spatial;和实体框架与Server数据库。现在我切换到使用MySQL服务器,当我创建与DbGeography类型相关的数据库时,我收到了一个错误。 public string Name { get; set; }
public DbGeography Location
当试图向实体添加DbGeography属性时,执行时会得到以下错误: Geocoder.DbGeography: : EntityType 'DbGeography' has no key defined.DbGeographies: EntityType: EntitySet 'DbGeographies' is based on type