I can not make a sample mvc3. Exception: Dialect does not support variable limits.
var query = _shopRepository.Get<IProduct>().Query(); if (model.Page > 0 && model.Size > 0) { query = query.Skip((model.Page - 1)*model.Size); } query = query.Take(model.Size); return query.ToList();