Question Compact & Close database option

sys_analyst47

Majid Pervaiz
Local time
Today, 23:54
Joined
Mar 9, 2010
Messages
11
Dear All,

Can someone please elaborate the usage of Compact & close database option.
What is happening with me when i select this option from MS Access options so when i close the database my main database is simply deleted and when i don't select compact & close option that's working fine and not deleting my file.

Would appreciate your kind response.
 
I think your existing database is copied and given a different name, then the old one is being deleted and the new one is renamed.

Catalina
 
I agree with Catalina.
C and R will rename your database, compact/repair your file, and then rename it.

If your concern was partly why you should use C and R , then from my experience, Access manages the queries/reports/table/procedures/forms etc. When you delete a table or query or any object, the item is deleted, but the space that it occupied (also called garbage) is still marked as used to Access. You will notice, if you run some queries or build then delete some temporary tables, that the space taken for you mdb/accdb file has grown considerably. By doing the C and R, Access now collects and removes these garbage entries and makes them available for use by you. There are other checks done as well to repair "fixable issues" - perhaps a bad index or an update to system tables. If you delete all the records in a table with an autonumber field, the autonumber will be reset to 0. I'm sure there are many more things, but that's an overview.

Here's a link
http://office.microsoft.com/en-ca/access-help/compact-and-repair-an-access-file-HP005187449.aspx
 
Last edited:

Users who are viewing this thread

Back
Top Bottom