[Solved] IQueryable with Entity Framework – order, where, skip and take have no effect


You are not using the result of query

IQueryable<StammdatenEntityModel> query = dbSet;
query = query.OrderByDescending(s => s.CreateDateTime);
query = query.Where(s => s.Deleted == false);
if(!String.IsNullOrEmpty(keyword))
{
    query = query.Where(s => s.SerialNumber.Contains(keyword)); //simplified for SO
}
query = query.Skip(skip);
query = query.Take(take);

0

solved IQueryable with Entity Framework – order, where, skip and take have no effect