I am working with Entity Framework. I don't have enough experience to solve any kinds of problem. The problem I am facing now is this: I have two classes as shown here:
public class AspNetUser: NormalUser
{
[Key]
public string UserId { get; set; }
public string PIN { get; set; }
public string FullName { get { return this.LastName + " , " + this.FirstName; } }
}
public class OfferReview
{
[Key]
public string OfferReviewId { get; set; }
public string UserId { get; set; }
public string Review { get; set; }
public virtual AspNetUser User { get; set; }
}
I need to bind all OfferReview property with AspNetUser.FullName property ==> I tried like this:
return context.OfferReviews
.Where(It => It.OfferId == offerId)
.Include(it => it.User.FullName)
.ToList();
Here offerId is a function parameter. I'm unable to show the full function....
I can easily get the above requirement with the help of linq join. But I want something above like lambda expression.
Is it possible? Or if possible how also if not possible then is there any other way? Please help