Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

WScript / MS access db compacting

Status
Not open for further replies.

Darrylles

Programmer
Feb 7, 2002
1,758
0
0
GB
Imagine a remote system where there are a large number of MS Access database apps (a lot created by 'laymen'), many poorly defined / designed / produced.
(You may find this easy to do).
Some are having problems with exceeding the 2gb max database size, which in turn creates issues of locked sessions / corruption etc.
They frequently need 'manually' compacting. (Yep - I can go through every one, and add code to do just that, but, that's in future - one step at a time).

An easy, double-clicked VBScript can be created to compact these databases (following backing up, checking database is closed, various error checking within the script).
This works fine, but is a little 'loose'. E.g. on failure, there could be better 'clean-up' etc., but scripts aren't the best for this process.

So, I decided to try encapsulating this in an MS Access app. (now using a pre defined list of applications, with their paths, storing who / when compacted, pre & post sizes etc.).
All databases can now be compacted from this single, centralised app.

Both the MS Access app and the 'script' method will be run from a client laptop, processing MS Access databases on a remote network server.
I know that the laptop doesn't even need MS Access installed to be able to perform that script 'compact' (as Windows has a DB 'engine' installed by default).
It of course DOES need MS Access to run the MS Access 'compact' application.

Question - (and it may sound silly, but no-one knows what they don't know):

Does the laptop cpu / memory undergo the same amount of work to perform the compact process via it's 'script', as much as it does via it's MS Access application?
(Here's where it's fuzzy for me - I 'get' that the laptop 'does it all' for the MS Access application that performs the compact - dragging all data locally, from the network, but is the script command 'passed' to the network, or, is the laptop still performing the actual compact process itself (dragging ALL data across from the network - onto the laptop).

I hope I've been clear enough to define the problem accurately, if not - please let me know.

Thanks for any pointers on this.

ATB,

Darrylle
 
Access Databases are what is known as File Server databases. This means the database engine is run on the client and all database operations are run as file edits to the operating system. So no there is no file access savings by one option or the other. It is possible that you are instantiating the Access application to compact via vba and that likely has more memory and load time for unnecessary parts vs the script. I am not familiar with the native tools for compacting. Likely however the local disk is fast enough and there is sufficient Ram that you probably wouldn't notice a problem other than maybe some latency between executions for loading.

That said the other method is RDBMS - Relational Database Management System (Oracle, SQL Server, etc.) These are database engine programs run on the server.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top