ASP.NET Performance Tips
page 3 of 19
by Adiseshu Dasari
Average Rating: 
Views (Total / Last 10 Days): 75191/ 181

Paged Data access

The ASP.NET DataGrid exposes a wonderful capability: data paging support. When paging is enabled in the DataGrid, a fixed number of records are shown at a time. Additionally, paging UI is also shown at the bottom of the DataGrid for navigating through the records. The paging UI allows you to navigate backwards and forwards through displayed data, displaying a fixed number of records at a time.

But there is a slight wrinkle in this. Paging with DataGrid requires that all the data needs to be bound to the grid. If 100,000 records are there, 99,975 records would be discarded on each request (assuming a page size of 25).

A better approach to avoid this is to use the stored procedure. SP should include logic for returning only the required number of rows for each request.

View Entire Article

User Comments

No comments posted yet.

Product Spotlight
Product Spotlight 

Community Advice: ASP | SQL | XML | Regular Expressions | Windows

©Copyright 1998-2024  |  Page Processed at 2024-05-27 8:01:24 AM  AspAlliance Recent Articles RSS Feed
About ASPAlliance | Newsgroups | Advertise | Authors | Email Lists | Feedback | Link To Us | Privacy | Search