English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
The BACKUP DATABASE command is used in SQL Server to create a full backup of an existing SQL database.
The following SQL statement creates a full backup of the existing database "testDB". To Drive D:
BACKUP DATABASE testDB TO DISK = 'D:\backups\testDB.bak';
Tip:Always back up the database to a different drive from the actual database. If the disk crashes, you will not lose the backup files and the database.
Differential backup only backs up the changed parts of the database that have been changed since the last full database backup.
The following SQL statement creates a differential backup of the database "testDB":
BACKUP DATABASE testDB TO DISK = 'D:\backups\testDB.bak' WITH DIFFERENTIAL;
Tip:Differential backup reduces backup time (because only changes are backed up).