Hello,
I have a web page with a datagrid. I'm using the built in paging
capabilities to allow paging. Each page shows 10 records.
When the page is first loaded, a thousand rows are retrieved from the db
into a dataset (on the server), and the first 10 are returned to the user to
fill the first page of the datagrid. This happens very quickly (1-2
seconds).
However, when the user clicks 'Next Page' to go to the next page of data in
the grid, the grid takes forever to show the second page (8-9 seconds). And
all I'm doing in code is changing the page index, retrieving the same 1000
rows into a dataset (on the server), and re-binding the grid to the dataset.
Running sql profiler against the database revealed that when the user clicks
'Next Page', the db doesn't get the call for 7-8 seconds.
Why does it take so long for the request to make its way from the client pc
to the server when 'Next Page' is clicked?
Thanks!!