I’m using this generic method to query for the info from my tables :
public virtual IQueryable<TObject> All()
{
return DbSetFilterDeleted.AsQueryable();
}
but for one of my tables I need to make JOIN so I need to modify this. I have a little experience with .NET at all but from my research I understand that AsQueryable() can be modified exactly for to serve these kind of purposes.
My question is how to modify it so that I can add to my query additional data, let say Post.Content where BlogId = FK_BlogId.
You need to employ
Includestatement in your queries.For instance, if you are querying
Posts and want to join relatedContents;and this will return an object of type
IQueryable<Post>.