Entity framework 实体框架核心继承”;无效列";

Entity framework 实体框架核心继承”;无效列";,entity-framework,entity-framework-core,Entity Framework,Entity Framework Core,在EF Core 3.1的代码第一次实现中,我有以下三个实体: [表(“客户”)] 公共类客户 { 公共int Id{get;set;} 公共虚拟ICollection地址{get;set;}=new HashSet(); } [表(“客户地址”)] 公共类CustomerAddress:AddressBase { [ForeignKey(“FK\U地址\客户\客户Id \客户Id”)] public int CustomerId{get;set;} 公共客户客户{get;set;} } [表(

在EF Core 3.1的代码第一次实现中,我有以下三个实体:

[表(“客户”)]
公共类客户
{
公共int Id{get;set;}
公共虚拟ICollection地址{get;set;}=new HashSet();
}
[表(“客户地址”)]
公共类CustomerAddress:AddressBase
{
[ForeignKey(“FK\U地址\客户\客户Id \客户Id”)]
public int CustomerId{get;set;}
公共客户客户{get;set;}
}
[表(“地址”)]
公共抽象类AddressBase
{
公共int Id{get;set;}
公共可空活动{get;set;}
[MaxLength(50)]
公共字符串StreetAddress{get;set;}
}
这是我的密码:

var customer=new customer(){Name=“GetAddresses”,CreatedAt=new DateTimeOffset(DateTime.Now)};
context.Customers.Add(客户);
SaveChanges();
customer.address.Add(new CustomerAddress(){CustomerId=customer.Id,customer=customer,StreetAddress=“100 Main St.”,CreatedAt=new DateTimeOffset(DateTime.Now)});
customer.address.Add(new CustomerAddress(){CustomerId=customer.Id,customer=customer,StreetAddress=“101 Main St.”,CreatedAt=new DateTimeOffset(DateTime.Now)});
customer.address.Add(new CustomerAddress(){CustomerId=customer.Id,customer=customer,StreetAddress=“102 Main St.”,CreatedAt=new DateTimeOffset(DateTime.Now)});
SaveChanges();
客户被添加/保存得很好。 但是,在第二个
context.SaveChanges()
上,我收到一个SqlException错误,它说:

列名“活动”无效。
列名“StreetAddress”无效。
列名“Id”无效。
列名“Id”无效

另外,
AddressBase
类的所有剩余列(此处未显示)

我做错了什么