I think that you have to specify a ForeignKey
relation on the Customer
property that maps to the key property exists on the entity.
[Table("CUSTOMER_DETAIL")]
public class CustomerDetail
{
[Required]
[Column("CUSTOMER_DETAIL_ID")]
public int Id {get; set;}
// other fields
[ForeignKey("Id")]
public virtual Customer Customer {get; set;}
}
This question refers to a different error, but has a similar goal to what you are trying to achieve.