Backing Up a database

CarlM1975

Registered User.
Local time
Today, 16:59
Joined
Oct 29, 2008
Messages
24
Hi

Is it possible to create a backup or a copy of a database from code whilst in the database you wish to back up?

Thanks

Carl.
 
I know its not wise but I really need to do it, I cant for the life of me find a copy command that will let me do it though.
 
Hi,

I've never been able to find a way to copy a DB whilst it is running, but I have created a process whereby I have a daily backup of my DB.

Firstly I created a 2nd copy of my main DB and called it MainDBBU that's not it's real name, but you get the idea].

Then within the main DB I created a process writing VB to append critical tables to my MainDBBU, which overwrites the exact same tables in the MainDBBU. There's no need to append queries, forms, reports, macros or modules, because they don't change [unless you're gonna create queries, forms etc on the fly regularly, which then presents you with a different beast to deal with.

I find this works fine, I have to date had to use my backup DB once to replace my MainDB and it only took a matter of minutes.

I have a process that runs every hour during the working day, so any loss of data is kept to a minimum and to the last hour. At the end of the day the database is closed down whereby an end of day backup is actioned.

Our IT department runs a process everynight backing up our network, so a copy of both the main and backup DB is held by them. A just for extra paranoia, I have a copy of both on my PC's hard drive, which I backup once a day, so if the networks backup copy gets lost or damaged or the tapes are not available for whatever reason, I can still replace both from my PC's hard drive.

This may seem overkill, but it has served me well and saved me many a days headace and work.

Hope this is of assistance.

John
 

Users who are viewing this thread

Back
Top Bottom