The SQL BACKUP DATABASE Statement
The BACKUP DATABASE statement is used in SQL Server to create a full back up of an existing SQL database.
Syntax
BACKUP DATABASE databasename
TO DISK = 'filepath';
The SQL BACKUP WITH DIFFERENTIAL Statement
A differential back up only backs up the parts of the database that have changed since the last full database backup.
Example
BACKUP DATABASE databasenameYou can click on above box to edit the code and run again.
TO DISK = 'filepath'
WITH DIFFERENTIAL;
BACKUP DATABASE Example
The following SQL statement creates a full back up of the existing database newDB" to the D disk:
Example
BACKUP DATABASE newDBYou can click on above box to edit the code and run again.
TO DISK = 'D:\backups\newDB.bak';