in aspnet core EntityFrameworkCore I'm developing a generic class to handle db operations and I have a Read() method that retrieves data from db like this:
using (MyDbContext context = new MyDbContext())
{
var result = await context.Set<T>().ToListAsync();
return result;
}
Now I wold like to filter the data adding a where or something similiar, in order to be able to filter one or more Entitiy's properties, for exeample:
TypeId = 2
How can I get this?
.Where(...)
extension method forIQueryable
? – Daniel A. White