Click to See Complete Forum and Search --> : PRB: Refreshing large database tables


Jack Shainsky
February 16th, 2000, 11:02 AM
I'm developing a database application, connected to an Access database. In my application I'm using data controls to retrieve data from database tables. Some of the tables store tens and hundreds of thouthands records, so refreshing of data controls takes few minutes to execute and, therefore, undesirable.
My problem that the database can be changed from an external application, so the data controls should be able to work with added/changed data. My recordsets are dynaset type, so I assume, that thay should be connected to the database, and able to get recent changes from it, but I cannot find, how can I achieve this. Maybe someone can halp me with this or suggest another approach of database connecting, so that the full refresh would be unnessesary?
I think, it's common problem in large database programming, so there should be some solutions of it? Am I wrong?

Thank you in advance,

Jack.

Kyle Burns
February 16th, 2000, 11:08 AM
Do you actually need all of the data in the table to be sent to the control? Why not use result sets to grab chunks of information as needed?

Cakkie
February 16th, 2000, 11:14 AM
This is a problem i encountered a while ago, but the solution is only a bypass, and i'm not even sure if you are able to do this but, if you can, add a field to the table, a field in wich you keep the date and time when the record was last changed. This way when you get the table the first time, you can store it locally on your HD, when checking for changes (like every 5 minutes) do a query on the table filtering only there records who have a date/time later then the moment you got the table from the DB. With these records, update your locally stored db.

There one big drawback on this, the DB will grow quit a bit, if you have to add a field to about 50.000 records. This can make the DB a lot bigger so be sure to compress the DB from time to time. Anyway, this might just not be a complete solution, but it sure saves you a lot of time.

Tom Cannaerts
slisse@planetinternet.be

The best way to escape a problem, is to solve it.

Jack Shainsky
February 16th, 2000, 11:19 AM
Unfortunately, I need it all, for example I need to allow the user to view all records in the grid etc. :-(

Jack.