Windows Application For Backup and Restore Database

In case that we develop various applications in development computer and want those applications to move on the client computer or any other computer for testing except that we need to copy those files, we need also backup the database and restore it. Other case if we want the end of the day to do database backup because we have modified or added something to it.

From both the aforementioned cases to make the backup and restore database on different computers with faster and easier way, I was inspired to develop a simple windows application called Backup&Restore that will do it without having to open SQL Server Management Studio. The following will describe the use of this application.

First choose if we want to backup or restore database.

If we choose Backup option do as follows:

In field “Server Name” type the name of the server on which is the database for backup, for example “LINDAF \SQL1” where SQL1 is the SQL instance name;

In field “Database Name” type the name of the database you want to make backup;

Click button “Choose Path” and is shown the following dialogue to select the folder where we want to store database backup file. If we choose the folder then press the button “OK”, the path appears and finally press “Run” button.

If it is successfully completed message appears as follows, otherwise appears message “BACKUP DATABASE not successfully!”

The backup file is saved with name of database and the current date when the backup is occurred.
If we choose Restore option do as follows:

In case if we want to do restore database “dbTest” to another database for example “dbOther” then we need to check the checkbox “Restore Other Database” and to type name of other database, otherwise press the button “Open File” to select the backup file. Finally press “Run” button. If it is successfully completed message appears as follows, otherwise appears message “RESTORE DATABASE not successfully!”

Hope you liked this simple application and if you have similar ideas please post them.
Advertisements
This entry was posted in Windows Applications and tagged , , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s