dcsimg
HTML Page taking time to Download
4 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Bharath_Krishna
Posted On:   Tuesday, January 28, 2003 09:56 PM

I have more than 5000 records in the DB. I am reading the records from the DB and putting that in the list box. I want to show all the records in the list box . The basic flow is, I read the data from the DB and put that in a Array List . I parse thru the ArrayList and puts it into the List Box . At the Server Side I could check the time taken for this is about 5 secs. . In local intranet it takes about 6 secs for the page to the displayed in the clients browser. But when I access this page over the internet it takes about 40 secs for the page to download. Is there any way of optimizing this. Note that I need to show all the 5000 records in the List box. Please let me know about this as   More>>

I have more than 5000 records in the DB.
I am reading the records from the DB and putting that in the list box.
I want to show all the records in the list box
.
The basic flow is, I read the data from the DB and put that in a Array List
. I parse thru the ArrayList and puts it into the List Box
. At the Server Side I could check the time taken for this is about 5 secs.
. In local intranet it takes about 6 secs for the page to the displayed in the clients browser.
But when I access this page over the internet it takes about 40 secs for the page to download.
Is there any way of optimizing this. Note that I need to show all the 5000 records in the List box.
Please let me know about this as this is very urgent.


Thanks


Bharath Krishna

   <<Less

Re: HTML Page taking time to Download

Posted By:   Sujatha_Gopal  
Posted On:   Thursday, January 30, 2003 09:12 PM

Instead of reading all the records at a time Show the Indexing From A - Z.


By Default Fill in the List Box staring with A.


On request from the user of the desired character fill the Data in the List Box.




Hope the solution will help to some extent.

Re: HTML Page taking time to Download

Posted By:   Christopher_Koenigsberg  
Posted On:   Wednesday, January 29, 2003 07:04 AM

Also I hope you don't mean an HTML "select" when you say "List Box", because I think there is an absolute limit, on the number of "option" elements that can occur, inside a "select"...

List box abuse!

Posted By:   Roger_Hand  
Posted On:   Wednesday, January 29, 2003 12:53 AM

Note that I need to show all the 5000 records in the List box.


This is where I would raise my voice at the spec meeting ...

Re: HTML Page taking time to Download

Posted By:   James_Bayer  
Posted On:   Tuesday, January 28, 2003 10:03 PM

I suspect that the html output from the servlet or jsp is so big, that it would be hard to optimize it much more (based off of you input that it happens fast when you have a local connection). See how big the html output is by viewing the source and determining whether it makes sense that it is taking that long.


If that is the case, you could do a couple of things to speed it up. You could cache the results on the server so you don't have the hit the database each time (unless perhaps the user requests it). also, to speed up the transfer to the client, do some refreshing tricks to gradually build up the page or simply trim down the html generation a lot.



one way of doing this is to just create a javascript array with the results you want and have javascript on the client actually "document.write()" the html out on the client side.
About | Sitemap | Contact