I have this model:
public class User
{
//other properties
public List<Task> Tasks {get;set;}
}
How can I select all properties of user and only Tasks with Date = DateTime.Today?
Can I do this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This would populate the
user.Taskscollection with the selected tasks automatically if the relationship is not many-to-many. If you only want another object (anonymous or some other non-entity class) with selected data from the user entity you can use: