public class Transaction {
//10 fields
public Claim ClaimNavigate { get; set; }
}
public class Claim {
//20 fields
}
public class Cms : Claim {
//50 fields
}
public class Ub : Claim {
//80 fields
}
dbContext.Transactions.Include(x => x.Claim).First()
dbContext.Claims.First() // also returns all derived types, how to return Base only?
有没有一种方法可以只包含Claim的字段,而不是将所有继承的Claim的所有字段自动添加到sql中?