How to Backup MS Access Database?

P

Prabhat

Hi Friends,

My Application is connected to MS Access database. I want to provide one
option as Backup and another option for Restore. I use Delphi 5 with ADO to
connect DB.

What is the best way to Backup the Dabase and Restore it?

I think as this is a Filebased DB, We should Make a Copy of the Database
file (.mdb) and Compact the new copied file.

Please suggest any idea. If i can get some Code fragment it will be helpful
for me.

Thanks
Prabhat
http://prabhatnath.blogspot.com
 
D

David W. Fenton

Copying the file is the best way to back it up.

I am informed in another forum that Access 2003 has a BACKUP option
on the database utilities menu. Is this true? And, of so, how does
it work?
 
P

Paul Shapiro

You were informed correctly. I never noticed it before, but it's there. It
just makes a physical copy of the .mdb file, defaulting to adding the date
to the file name, like "_2007-05-23". The backed up copy is an mdb file.

From the help file:
Back up an Access database

1.. Save and close all objects in the database.
2.. On the File menu, click Back Up Database.
3.. In the Save Backup As dialog box, specify the name and location of the
backup copy.
 
T

Tom Wickerath MDB

it is impossible to reliably backup an access MDB database

you shoudl move to SQL Server; this has the 'maintenance plan wizard' built
into the product
 
D

David W. Fenton

You were informed correctly. I never noticed it before, but it's
there. It just makes a physical copy of the .mdb file, defaulting
to adding the date to the file name, like "_2007-05-23". The
backed up copy is an mdb file.

From the help file:
Back up an Access database

1.. Save and close all objects in the database.
2.. On the File menu, click Back Up Database.
3.. In the Save Backup As dialog box, specify the name and
location of the
backup copy.

If you can tell, does it use a file copy (i.e., closes the database
and copies it) or does it compact to the new filename or use some
other Jet command to create the backup?
 
P

Prabhat

If you can tell, does it use a file copy (i.e., closes the database
and copies it) or does it compact to the new filename or use some
other Jet command to create the backup?

--
Hi,

I have tested the Backup procedure in MS Access. It is using the Jet Command
(JRO) to Compact the Database and Copy it with the "Date" added to the DB
file name.

Thanks
Prabhat
http://prabhatnath.blogspot.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top