What if you want to skip Top N
rows while doing a select
statement in sql server
? Try this
1
2
3
4
5
6
7
DECLARE @count INT = 5
SELECT *
FROM <<Table>>
WHERE <condition>
ORDER BY <<column>>
OFFSET @count ROWS
Hope this helped.
What if you want to skip Top N
rows while doing a select
statement in sql server
? Try this
1
2
3
4
5
6
7
DECLARE @count INT = 5
SELECT *
FROM <<Table>>
WHERE <condition>
ORDER BY <<column>>
OFFSET @count ROWS
Hope this helped.