devxlogo

Copying a Database

Copying a Database

Question:
What’s an easy way to make a copy of a currently open database? I’ve got open recordsets all over the place that I don’t want to close.

Answer:
Simply use theCompactDatabase method on the DBEngine object, oralternatively the CompactDatabase statement. ThisREQUIRES copying the database file to a new file,and has the added effect of compacting records,removing deleted records, and otherwise making fora cleaner copy.

devx-admin

Share the Post: