SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


backup scripts


backup scripts

Author
Message
sql.pravin
sql.pravin
SSC-Enthusiastic
SSC-Enthusiastic (138 reputation)SSC-Enthusiastic (138 reputation)SSC-Enthusiastic (138 reputation)SSC-Enthusiastic (138 reputation)SSC-Enthusiastic (138 reputation)SSC-Enthusiastic (138 reputation)SSC-Enthusiastic (138 reputation)SSC-Enthusiastic (138 reputation)

Group: General Forum Members
Points: 138 Visits: 72
hi everyone,

i need a script (stored proc ) to identify all user databases in a server and then apply full backup, differential backup and transactional backup to them ( with their specific schedules )

and it should automatically delete all the backups keeping 2 recent backups in all the 3 types(full, diff, tran)

thanks,
praveen
alen teplitsky
alen teplitsky
SSChampion
SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)SSChampion (11K reputation)

Group: General Forum Members
Points: 11106 Visits: 4674
try SSIS
Steve Turner - SQL Managed
Steve Turner - SQL Managed
Old Hand
Old Hand (388 reputation)Old Hand (388 reputation)Old Hand (388 reputation)Old Hand (388 reputation)Old Hand (388 reputation)Old Hand (388 reputation)Old Hand (388 reputation)Old Hand (388 reputation)

Group: General Forum Members
Points: 388 Visits: 235
Check out this article, it will get you going in the right direction. It's a stored procedure for making Full, Diff, and Trans backups. Variables to pass in are database name and backup type.


http://www.mydigitallife.info/2009/08/26/how-to-perform-scheduled-backups-for-sql-server-2005-express/comment-page-1/


Steve

SQL Managed
Steve Jones
Steve Jones
SSC Guru
SSC Guru (222K reputation)SSC Guru (222K reputation)SSC Guru (222K reputation)SSC Guru (222K reputation)SSC Guru (222K reputation)SSC Guru (222K reputation)SSC Guru (222K reputation)SSC Guru (222K reputation)

Group: Administrators
Points: 222006 Visits: 19618
A maintenance plan can do this as well.

Follow me on Twitter: @way0utwest
Forum Etiquette: How to post data/code on a forum to get the best help
My Blog: www.voiceofthedba.com
SQLRNNR
SQLRNNR
SSC Guru
SSC Guru (99K reputation)SSC Guru (99K reputation)SSC Guru (99K reputation)SSC Guru (99K reputation)SSC Guru (99K reputation)SSC Guru (99K reputation)SSC Guru (99K reputation)SSC Guru (99K reputation)

Group: General Forum Members
Points: 99356 Visits: 18616
Though the maintenance plan and ssis options are perfectly sound, here is a list of some possible scripts.



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw

muthukkumaran Kaliyamoorthy
muthukkumaran Kaliyamoorthy
SSCertifiable
SSCertifiable (7.2K reputation)SSCertifiable (7.2K reputation)SSCertifiable (7.2K reputation)SSCertifiable (7.2K reputation)SSCertifiable (7.2K reputation)SSCertifiable (7.2K reputation)SSCertifiable (7.2K reputation)SSCertifiable (7.2K reputation)

Group: General Forum Members
Points: 7167 Visits: 4990
sql.pravin (11/19/2009)
hi everyone,

i need a script (stored proc ) to identify all user databases in a server and then apply full backup, differential backup and transactional backup to them ( with their specific schedules )

and it should automatically delete all the backups keeping 2 recent backups in all the 3 types(full, diff, tran)

thanks,
praveen


Hi Praveen,
Check the links

For Backup
http://www.mssqltips.com/tip.asp?tip=1599

For Cleanup
http://www.sqlservercentral.com/Forums/Topic801727-1557-1.aspx

Muthukkumaran Kaliyamoorthy

Helping SQL DBAs and Developers >>>SqlserverBlogForum

Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search