[URGENT]Database to XML file asp.net

Posted by Write2varun under ASP.NET on 9/18/2013 | Points: 10 | Views : 1923 | Status : [Member] | Replies : 2

I'm creating a Page in which, while Page_Load.

I'm taking the data from the database and writing it to the XML file.
My problem is I'm having a lot of data in the database so while creating the XML file it is taking a lot of time, which is not working for me.

I need to write the data in 2 to 3 seconds.
Please, I really need help to write the data.

I took the help from :

Thanks in advance.


Posted by: Bandi on: 9/18/2013 [Member] [MVP] Platinum | Points: 25

I doesn't have exact solution.. I can suggest one workaround...
1) We should process the data batch-wise in the case of large volume of data...
Use limit in your query to fetch only limited records and keep it in your session variable. once you reach the exhaustion limit on either side (say 10 in <next> or 1 in <prev>), then query the next 10 records.

So user will have only the limit of records in session to view and querying the whole load information is avoided
And do you have proper indexes on tables? if there is indexes on table columns it might help you in the process of speed loading

Refer http://forums.asp.net/t/1810340.aspx

Mark This Response as Answer

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

Posted by: Write2varun on: 9/18/2013 [Member] Starter | Points: 25

hello, your reply is really helpful but please help me i don't know how to do paging while selecting the data from sql server

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

Login to post response