TDP MSSQL database backup stratagy: script help needed

microosoft

Active Newcomer
Joined
Aug 23, 2009
Messages
8
Reaction score
0
Points
0
Hi,

I am working at a place where we have Microsoft MSSQL as our RDBMs and TSM TDP for Tape backup. We have a Policy of Monthly Full backup and daily differentials on all of our instances.

But there is one instance where MSSQL databases are created every day. i would like to run a full backup on newly created databases followed by a differential backup on all the databases everyday until month end and then run a full backup on all the databases on first of every month. is there a way to schedule it?

i need:

Daily full backup on newly created databases on that day ( script needed )
followed by differential backup on all databases everyday( i have this schedule script)
full backup on all databases every month ( i have this schedule script)

Thanks,
Mike
 
You can use osql to query your MSSQL in your TDP batch script. Something like:

osql -E -q "select name from master..sysdatabases where crdate > '<date here>'

you will have to obtain the date in advance in your script. Then you can use the result on your tdpsqlc backup command.

Rudy
 
There are a number of enhancements. You can do the regular scripting, similar to V5 or you can use the Templates provided within the MMC plug-in and there is now a power-shell window that you can utilize as well. Whatever makes you comfortable.
 
power shell scripting

There are a number of enhancements. You can do the regular scripting, similar to V5 or you can use the Templates provided within the MMC plug-in and there is now a power-shell window that you can utilize as well. Whatever makes you comfortable.

Is there scripts for power shell ??
 
Back
Top