Compact & Repair Database (Reading)
Compact and Repair your Database
Website Source: Microsoft Access Links to an external site.
Running the Compact and Repair Database utility within Access can improve the performance of your database. This utility makes a copy of the database file and, if it is fragmented, rearranges how the database file is stored on disk. After the compact and repair process has completed, the compacted database will have reclaimed wasted space, and is usually smaller than the original. By compacting the database frequently, you can help ensure optimal performance of the database application, and also resolve errors that arise from hardware problems, power failures or surges, and similar causes.
After the compact operation has completed, query speed is enhanced because the underlying data has been rewritten to the tables in contiguous pages. Scanning contiguous pages is much faster than scanning fragmented pages. Queries are also optimized after each database compaction.
During the compact operation, you can use the original name for the compacted database file, or you can use a different name to create a separate file. If you use the same name and the database is compacted successfully, Access automatically replaces the original file with the compacted version.
Set an option that automates this process
-
Click File > Options to open the Access Options dialog box.
-
Click Current Database and, under Application Options, select the Compact on Close check box.
This causes Access to automatically compact and repair the database every time it is closed.
Manually compact and repair your database
-
Click Database Tools > Compact and Repair Database.