Browse by Tags

All Tags » backup (RSS)

Backup Database

This query will backup the current database declare @sql varchar(1000) select @sql = 'BACKUP DATABASE '+(select db_name())+' TO DISK = ''E:\'+(select db_name())+ convert(varchar,GETDATE(),112)+'.bak''' Exec(@sql) If the database name is Test then executing...
Posted by Madhivanan | with no comments