Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > How to optimize datagrid loading speed

Reply
Thread Tools

How to optimize datagrid loading speed

 
 
Reddy
Guest
Posts: n/a
 
      01-19-2004
The sql query for my datagrid returns 100, 000 records. But the datagrid
should display 20 records per page. I am using datagrid paging, but it is
taking too much time for the page to load. Is there any way I can optimize
the speed. Any sample code would be great.

Thanks,

Reddy


 
Reply With Quote
 
 
 
 
Alvin Bruney
Guest
Posts: n/a
 
      01-19-2004
There is no way to optimize the speed. 100k records will take a long time to
load. There is no way around that. What you can do is implement custom
paging and keep going to the database for pages of 20 rows, that way you are
carrying 20 records per trip. Loading 100,000 records is a seriously bad
idea anyway. Memory allocation and deallocation will be a problem causing
your app to recycle.

One approach used by some websites is to have an index at the top of the
page, usually an alphabetized listing. Clicking on a letter gets just the
records for that letter. It's all in an effort to reduce the large number of
records going back and forth.

--
Regards,
Alvin Bruney
Got tidbits? Get it here...
http://tinyurl.com/3he3b
"Reddy" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> The sql query for my datagrid returns 100, 000 records. But the datagrid
> should display 20 records per page. I am using datagrid paging, but it is
> taking too much time for the page to load. Is there any way I can optimize
> the speed. Any sample code would be great.
>
> Thanks,
>
> Reddy
>
>



 
Reply With Quote
 
 
 
 
Reddy
Guest
Posts: n/a
 
      01-20-2004
Thanks Alvin.

In the old ADO we used to optomize it for around 50,000 records. Thought
there might a way around in .NET as well.

Regards,


"Alvin Bruney" <vapor at steaming post office> wrote in message
news:(E-Mail Removed)...
> There is no way to optimize the speed. 100k records will take a long time

to
> load. There is no way around that. What you can do is implement custom
> paging and keep going to the database for pages of 20 rows, that way you

are
> carrying 20 records per trip. Loading 100,000 records is a seriously bad
> idea anyway. Memory allocation and deallocation will be a problem causing
> your app to recycle.
>
> One approach used by some websites is to have an index at the top of the
> page, usually an alphabetized listing. Clicking on a letter gets just the
> records for that letter. It's all in an effort to reduce the large number

of
> records going back and forth.
>
> --
> Regards,
> Alvin Bruney
> Got tidbits? Get it here...
> http://tinyurl.com/3he3b
> "Reddy" <(E-Mail Removed)> wrote in message
> news:%(E-Mail Removed)...
> > The sql query for my datagrid returns 100, 000 records. But the datagrid
> > should display 20 records per page. I am using datagrid paging, but it

is
> > taking too much time for the page to load. Is there any way I can

optimize
> > the speed. Any sample code would be great.
> >
> > Thanks,
> >
> > Reddy
> >
> >

>
>



 
Reply With Quote
 
Alvin Bruney
Guest
Posts: n/a
 
      01-20-2004
what do you mean optimize it for 50,000 records? Maybe I'm over-looking
something. Can you explain how you would do this?

--
Regards,
Alvin Bruney
Got tidbits? Get it here...
http://tinyurl.com/3he3b
"Reddy" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Thanks Alvin.
>
> In the old ADO we used to optomize it for around 50,000 records. Thought
> there might a way around in .NET as well.
>
> Regards,
>
>
> "Alvin Bruney" <vapor at steaming post office> wrote in message
> news:(E-Mail Removed)...
> > There is no way to optimize the speed. 100k records will take a long

time
> to
> > load. There is no way around that. What you can do is implement custom
> > paging and keep going to the database for pages of 20 rows, that way you

> are
> > carrying 20 records per trip. Loading 100,000 records is a seriously bad
> > idea anyway. Memory allocation and deallocation will be a problem

causing
> > your app to recycle.
> >
> > One approach used by some websites is to have an index at the top of the
> > page, usually an alphabetized listing. Clicking on a letter gets just

the
> > records for that letter. It's all in an effort to reduce the large

number
> of
> > records going back and forth.
> >
> > --
> > Regards,
> > Alvin Bruney
> > Got tidbits? Get it here...
> > http://tinyurl.com/3he3b
> > "Reddy" <(E-Mail Removed)> wrote in message
> > news:%(E-Mail Removed)...
> > > The sql query for my datagrid returns 100, 000 records. But the

datagrid
> > > should display 20 records per page. I am using datagrid paging, but it

> is
> > > taking too much time for the page to load. Is there any way I can

> optimize
> > > the speed. Any sample code would be great.
> > >
> > > Thanks,
> > >
> > > Reddy
> > >
> > >

> >
> >

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
7 Ways to Speed up and Optimize Windows XP Code name 47 Digital Photography 5 04-06-2007 01:50 AM
7 Ways to Speed up and Optimize Windows XP Code name 47 Computer Support 0 04-01-2007 02:45 PM
Best choice to optimize datagrid paging and sort ?? =?Utf-8?B?U2FjaGk=?= ASP .Net 1 04-21-2005 09:04 AM
optimize error:left bound range doesn't evaluate to a const. senthil VHDL 0 03-04-2004 03:02 AM
speed speed speed a.metselaar Computer Support 14 12-30-2003 03:34 AM



Advertisments