Compacting a Database

Access 97
Access 2000

As you work with your database, you might notice that the file size of your database increases. While that is a natural result of adding records, there is a compact feature in Microsoft Access that helps keep this file size to a minimum. By removing unused spaces in the database file, the compact feature reorganizes the database file into a more efficient and compact size. This process is entirely safe and will also help large databases run faster. In Access 97, this process has to be done manually, but in Access 2000, this can be set to automatically compact every time you close your database. Whatever version you are running, it is a good idea to periodically compact your database. This Access tip shows you the few steps needed to run this function.

Access 97

  1. With your database open, click Tools.
  2. Click Database Utilities.
  3. Click Compact Database.

Those are the only steps needed to compact your database.

If you also wish to run the "Repair" feature, the steps are much the same:

  1. With your database open, click Tools.
  2. Click Database Utilities.
  3. Click Repair Database.

 

Access 2000

To manually compact a database:

  1. With your database open, click Tools.
  2. Click Database Utilities.
  3. Click Compact and Repair Database.

To compact automatically when you close a database:

  1. With your database open, click Tools.
  2. Click Options.
  3. On the Options window, click the General Tab.
  4. At the bottom left of this window, click the check box option called Compact on Close.
  5. Click OK.

Now your database will compact itself each time you close the database. Keep in mind, this option is only available in Access 2000.