U kunt ROW_NUMBER
. gebruiken in TSQL (vanaf 2005) om dit te doen:
SELECT ID, Foo, Bar
FROM (SELECT ROW_NUMBER() OVER (ORDER BY ID ASC) AS Row,
ID, Foo, Bar
FROM SomeTable) tmp
WHERE Row >= 50 AND Row <= 100
Of met LINQ-naar-SQL enz.:
var qry = ctx.Table.Skip(50).Take(50); // or similar