![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi We have some some systems, which save a lot of detailed/temporary data to an access table (some ~10 tables in a file), and 3-4 tables are heavily updated every half our a summeriser goes over it, puts summarised data into some other tables, and delete old data. As of now, they system has not been packing itself automatically, but we have added that now. The question is, does that solve our problem? Packing is done once a week, or when 15% of temp data are deleted. Packing is also done, when the error [Microsoft][ODBC Microsoft Access Driver] Record is deleted occurs - that error is easily fixeable byt packing but there are 2 other scenaries: 1) "bookmark not valid" - this errors happen now and then. Solution: open it a use "compact and repair" from the tools - db tools menu 2) "Could not update; currently locked by user 'admin' on machine 'J-54453946E8D'" "Could not read; currently locked by user 'admin' on machine 'J-54453946E8D'" and "You attempted to open a database that is already opened exclusively by user 'admin' on machine XXXXX. Try again when DB is available." It works so, that the summariser (a thread) can set a flag, which will initiate the packing thread - basically without any delay except what it within windows (and that is surprisingly slow). Could it be, that I should wait a bit more? The packing thread will set a flag in other threads forcing them to stop, and wait for them to do so. That should not be a problem, and my test case does not save at all, and still I get this - though rarely. In real systems the errors in 2) comes from both saver thread and summarised thread. The saver thread caches data, and saves them using insert.... there is an ID, which the thread itself handles. That has not caused problems so far. Basically, I want to overcome those problems automatically. As of now packing is forced as described above, but can anyone explain then problems in 1) and 2) ? WBR Sonnich |
#3
| |||
| |||
|
|
jodleren wrote: Hi We have some some systems, which save a lot of detailed/temporary data to an access table (some ~10 tables in a file), and 3-4 tables are heavily updated every half our a summeriser goes over it, puts summarised data into some other tables, and delete old data. As of now, they system has not been packing itself automatically, but we have added that now. The question is, does that solve our problem? Packing is done once a week, or when 15% of temp data are deleted. Packing is also done, when the error [Microsoft][ODBC Microsoft Access Driver] Record is deleted *occurs - that error is easily fixeable byt packing but there are 2 other scenaries: 1) "bookmark not valid" - this errors happen now and then. Solution: open it a use "compact and repair" from the tools - db tools menu 2) "Could not update; currently locked by user 'admin' on machine 'J-54453946E8D'" "Could not read; currently locked by user 'admin' on machine 'J-54453946E8D'" and "You attempted to open a database that is already opened exclusively by user 'admin' on machine XXXXX. Try again when DB is available." It works so, that the summariser (a thread) can set a flag, which will initiate the packing thread - basically without any delay except what it within windows (and that is surprisingly slow). Could it be, that I should wait a bit more? The packing thread will set a flag in other threads forcing them to stop, and wait for them to do so. That should not be a problem, and my test case does not save at all, and still I get this - though rarely. In real systems the errors in 2) comes from both saver thread and summarised thread. The saver thread caches data, and saves them using insert.... there is an ID, which the thread itself handles. That has not caused problems so far. Basically, I want to overcome those problems automatically. As of now packing is forced as described above, but can anyone explain then problems in 1) and 2) ? WBR Sonnich For a bookmark problem, it may be something like doing something like searching for a record, deleting it, then attempting to assign it's bookmark to something else. Look at OpenDatabase Method in help (and your code). *Are you setting an Exclusive flag someplace? *On a desktop icon, does somebody have /excl to open that file in the shortcut properties? You might want to check if the file/tables can be opened prior to doing an update. |
![]() |
| Thread Tools | |
| Display Modes | |
| |