Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

yet another backup script usp_backup

By Wesley Brown,

I wrote this to backup to a network share you can set the backup to spool to the local disk first then it will move it to another drive or to a unc just fine. Directory to hold and move to are not optional but if you set them to the same path it won't hurt the script at all. This stored procedure will backup a single database or all databases it will also perform ether a full, diff, or tlog backup. this stored procedure is designed to take x parameters: @dbname : required, this is the database you wish to backup null or comma seperated list @bktype : required, this is the type of backup 0=full, 1=diff, 2=tlog @bkpath : required, this is the path can be a drive letter i.e. c:\bak or a unc \\myserver\bak @bkpathhold: required, this is the directory that backups are spooled to first usage usp_backup ,2,'',''

Total article views: 292 | Views in the last 30 days: 2
 
Related Articles
FORUM

calculating the size required for backup of database

calculating the size required for backup of database

FORUM

Database Backup

Database Backup

FORUM

Proper way to backup databases

backup databases

FORUM

Urgent Requirement

Database cleaning... Help required....

FORUM

database backup

database backup

 
Contribute

Join the most active online SQL Server Community

SQL knowledge, delivered daily, free:

Email address:  

You make SSC a better place

As a member of SQLServerCentral, you get free access to loads of fresh content: thousands of articles and SQL scripts, a library of free eBooks, a weekly database news roundup, a great Q & A platform… And it’s our huge, buzzing community of SQL Server Professionals that makes it such a success.

Join us!

Steve Jones
Editor, SQLServerCentral.com

Already a member? Jump in:

Email address:   Password:   Remember me: Forgotten your password?
Steve Jones