So you need to make a back up for your SELECTServer database for any number or reasons, but you are not sure how to accomplish this task. Below your will find three (3) ways to accomplish this and continue on with your day to day operations.
First things first...The hassel of a SELECTServer Database can be avoided by utilizing the Bentley Hosted Server! Learn more by clicking here:
Lets dive into the ways a SELECTServer Database can be backed up!
1. The easiest way to Back Up and Restore a database is by using an application known as SQL Manager Studio (or SQL Manager Studio Express)
· Simply open the application and log in using the appropriate credentials
· Drill down through the folders on the left hand side of the screen until you locate the database you want to Back Up
· Right click on the Database of your choice and in the drop down menu choose Tasks, then Backup
· On the next Screen select the database you are backing up, set the Backup type to "FULL" , define a directory in the Destination Settings and choose "OK"
· Your Database is now Backed Up!
2. The database can be backed up using the DBSupport page in the SELECTServer Administration Site.
· Open the admin site HTTP://<SERVERNAME>/BSS/Admin/Default.aspx
· Change the URL to HTTP://<SERVERNAME>/BSS/Admin/Default.aspx?Control=DBSupport
· In the text box provide enter...
o BACKUP DATABASE [DATABASE_NAME] TO DISK = N'[FILENAME]' WITH NOFORMAT, INIT, NAME = N'[DESCRIPTION]', SKIP, NOREWIND, NOUNLOAD, STATS = 10
o Replace [DATABASE_NAME] with the name of the database name - for convenience the Database name is listed in the Database Settings section above the textbox.
o Replace [FILENAME] with the name of the file to back the database up to. Note:If you specify only a filename then the file will be created in the BACKUP directory of SQL Server, or you can specify a fully qualified path like c:\temp\select_server_db.bak
o Replace [DESCRIPTION] with a description of the backup. - This will be used during a restore process.
To backup the Database named DEVELOPMENT To c:\temp\test.back
BACKUP DATABASE [Development] TO DISK = N'c:\temp\test.bak' WITH NOFORMAT, INIT, NAME = N'[Full Backup]', SKIP, NOREWIND, NOUNLOAD, STATS = 10
· Click the OK button
· You'll see the notice Query didn't change any DB rows appear below the text box.
3. The SELECTServer Database can be backed up by using a Command Prompt:
· backup <filename> - creates a backup of the currently configured database.
o <filename> full path and file name to backup the database to.
· /restore <filename> - restore the currently configured database from a file
o <filename> full path and file name to restore the database from.
· /drop - drops all of the tables and stored procedures in the current database
· /user=<username> - name of the user to connect to the SQL server with
· /pwd=<password> - password to use to connect to the SQL server with
· /dbname=<databasename> - name of the database instance to use. If a database by the name doesn't exist it will be created.
· /autorun - indicates to run the script without any user interaction
· /quiet - specifies to run the script without and display
The following command line will connect to the the SQL Server using user name "SA" password "apassword",
create a database named "trtest" and automatically run the script.
bentley.selectserver.database.setup.exe /user=sa /pwd=apassword /dbname=trtest /autorun /quiet
osql -S MyServerName -U user -P password -Q "BACKUP DATABASE [Database Name] TO DISK = N'c:\SSXM_DB_BACKUP.bak' WITH NOFORMAT, INIT, NAME = N'[Full Backup]', SKIP, NOREWIND, NOUNLOAD, STATS = 10"