Click here to Skip to main content
15,892,746 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello,
I have a huge problem when using the autocomplete textbox property with a huge data.
I have tried to load them before application load but the problem is any manipulating on data will not appear to other users unless they restarted the whole application.
The data is more than million record in database.
What I should do to improve my application and the changes appear to the other users not only on local datatable.
Posted

1 solution

I think you are going to have to use a query to the database as the autocomplete source. This way you avoid having to load all the data before hand.
 
Share this answer
 
Comments
Mohammad Nasser Eddin 11-Mar-12 6:40am    
thank you for answer
but even if I use a query it will send a query every time the user type a letter and that will make it costs more time and ram. Or what?
Wayne Gaylard 11-Mar-12 6:47am    
You are going to have to strike a balance between time and memory cost. What is more important ? A users time or memory use ? The benefit of using a query as the source is that you will be filtering the results right from the get go, and each resultset would get less and less, so you could try only querying for results after the user has typed a specific number of letters. Say you only query the database after the user has typed 3 letters in, then your resultset would be much fewer items.
Mohammad Nasser Eddin 11-Mar-12 6:53am    
Unfortunately the time cost is more important to me but the memory cost is very high the Application load cos at least 500 MB of RAM.
The requirement is to search from the first letter, it will filter at most 60% of data and still huge for query from database.
I would like to know if there is a way to make a direct connection between datatable and database with sync, if any change happen on one of them change the other?
and thanks again for helping me :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900