if i have 1000 records and i want to access 20 ata time
from SQL server, what will be the query?
Answer Posted / vijendra singh
Use The following Query for the problem...
Declare @PageIndex int
set @PageIndex=1
Declare @PageSize int
set @PageSize=20
while @PageIndex < 1000
begin
SELECT * FROM test WHERE ID between
@PageIndex and @PageIndex+@PageSize-1
set @PageIndex = @PageIndex + 20
end
| Is This Answer Correct ? | 13 Yes | 2 No |
Post New Answer View All Answers
How you can add an event handler?
Explain global assembly cache.
What are all the various Estimation Techniques available ?
How will you maintain versioning in asp.net 2.0?
What is the difference between user control an custom control?
Differentiate between namespace and assembly.
Is it possible for me to change my aspx file extension to some other name?
What is the significance of ASP.NET routing?
What are the new features implemented in ASP.NET?
What is the main function of url routing system in asp.net mvc? : asp.net mvc
How to store checkbox value in database in asp.net mvc? : Asp.Net MVC
Which is faster viewdata or viewbag?
What is repository pattern in mvc.net? : asp.net mvc
What are httphandlers and httpmodules and difference between them?
What are the types of session in asp.net?