Millions of record show possible in Grid view

Posted by Rajesh081725 under ASP.NET on 5/25/2017 | Points: 10 | Views : 322 | Status : [Member] | Replies : 7
How to show millions of records in the Grid view control using ASP.NET?

Can you provide the example of sample code.

Runtime gridview will show only 50 records on the same. But millions records show to only one page is possible?

Thanks,
Rajesh

Time is Gold
Thanks & Regards,
Rajesh Kumar,
9962038582.



Responses

Posted by: Raja on: 5/25/2017 [Member] Starter | Points: 25

Up
0
Down
What is the logic behind showing millions of records into a single page?

Theoretically it is possible provided your server, network bandwidth and database is fast and capable enough to provide those data in time.

No separate or special coding is required, just use typical coding to populate data into the GridView.

For example, you can read this post and know how to populate data into the GridView - http://www.dotnetfunda.com/articles/show/1400/how-to-generate-gridview-columns-dynamically-based-on-user-selection.

Thanks

Regards,
Raja, USA

Rajesh081725, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: A2H on: 5/25/2017 [Member] [MVP] Silver | Points: 25

Up
0
Down
When you display millions of records in a single page in gridview then there is a high change that you may face performance issue while doing any operations in gridview.
You might consider taking one of the below suggestion
Add paging to GridView and display set of records(say 50) in one page and user can got next page to view the other records. You might also add the filtering option to gridview so that they can filter the result and work on small result set instead of millions of records

Thanks,
A2H
My Blog

Rajesh081725, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: A2H on: 5/25/2017 [Member] [MVP] Silver | Points: 25

Up
0
Down
Another option is to implement Load on Demand during scroll. You can take a look at the below article for step by step instructions
https://www.aspsnippets.com/Articles/Load-on-demand-data-in-GridView-on-scroll-using-ASPNet-and-jQuery-AJAX.aspx

Thanks,
A2H
My Blog

Rajesh081725, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Rajesh081725 on: 5/26/2017 [Member] Bronze | Points: 25

Up
0
Down
i want to view the millions of records in GRID VIEW at same page.. I cant click next page.. Normally grid view will display 50 records per page. But my requirement is be display the millions of records at the single page.

Is it possible?

Time is Gold
Thanks & Regards,
Rajesh Kumar,
9962038582.

Rajesh081725, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Jitendrasoft09 on: 5/26/2017 [Member] [MVP] Starter | Points: 25

Up
0
Down
First of all Gridview is not indented to use to show millions of records. Any how if you need then you have to create a stored procedure which will prevent to load all millions of records in single page. It will show partial filtered records in single page. Mean your all millions of records will be in single page. All records will be in halt until user clicks on paging number. Here SP will take care of which range of records to be displayed. Scrolling features will be better than Gridview in performance wise. Hope it helps you. Go through the below link-
https://www.aspsnippets.com/Articles/Custom-Paging-in-ASPNet-GridView-using-SQL-Server-Stored-Procedure.aspx


Jitendra Kumar
If my post helps you, plz mark as an answer.

Rajesh081725, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Rajesh081725 on: 5/26/2017 [Member] Bronze | Points: 25

Up
0
Down
Hi Jitendra,

Thanks for your information.

I try to open this above mentioned url but its not working.

This site can’t be reached

https’s server DNS address could not be found error.



Time is Gold
Thanks & Regards,
Rajesh Kumar,
9962038582.

Rajesh081725, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Jitendrasoft09 on: 5/26/2017 [Member] [MVP] Starter | Points: 25

Up
0
Down
try it now.
https://www.aspsnippets.com/Articles/Custom-Paging-in-ASPNet-GridView-using-SQL-Server-Stored-Procedure.aspx

Jitendra Kumar
If my post helps you, plz mark as an answer.

Rajesh081725, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response