Link to home
Start Free TrialLog in
Avatar of donthee
dontheeFlag for United States of America

asked on

MDB Size After Compact & Repair

Following a "Save Operation Failed" error, I followed instructions found in another EE topic to decompile, re-compile and Compact and Repair the mdb.  This all seems to have worked fine, however, I notice that my mdb is now 1/2 the size it was previous to these procedures.  Having regularly compiled and C&R'ed the mdb, I wondered if this is reasonable... and why?  
Avatar of DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
Flag of United States of America image

Yes ... definitely. It will shrink typically a LOT.

mx
Why is because of the 'bloat' factor.  Adding, deleting objects in design, adding code and compiling code, adding data and deleting data ... all contribute to bloat.  C&R gets rid of the bloat.  This has been the case since Access 1.0.

And ... if you ZIP up an MDB ... the ZIP file is even smaller.  

mx
Avatar of donthee

ASKER

thanks for the quick reply.  even if regularly compacted and repaired?  27mb to 13 mb.  is there an explanation why the regular c&r doesn't do the same as the decompile, etc?
Avatar of donthee

ASKER

and does that mean the proper procedure should be to decompile, re-compile then c&r?
Normally, unless you encounter an error such as the one you did, only C&R s/b part of daily maintenance.

Actually, after you Decompile and then recompile ... the mdb will typically be larger.  Then, you do a C&R to bring it back down to the 'normal' size.  Almost anytime you compile, the MDB will get bigger ... due to the nature of how Compile works.

mx
You really shouldn't decompile unless you need to do so, or at the very least make a copy before you decompile. You should, however, compact and repair regularly as mx said.

Avatar of donthee

ASKER

one further comment then i'll accept your answers and up the points.  i have been watching the size of this mdb closely and its has been growing slowly in 20 something mb range.  as stated, i have been compacting and repairing regularly (with no recent previous errors) yet today, following the decompile, the size halved.  was something embedded that kept it up at 27mb that the decompile, etc today removed?  i still don't see why the regular, previous c&r'ing didn't produce the same size reduction.
thanks again.
ASKER CERTIFIED SOLUTION
Avatar of DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
DatabaseMX (Joe Anderson - Former Microsoft Access MVP)
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of donthee

ASKER

Thanks again, DatabaseMX.