Refresh / recreate backup job
Paul Allen
Posts: 3
We have created some sql backup jobs via the sqlbackup gui. The problem we have is that databases often get moved from 1 server to another. At the moment we are having to manually recreate the backup jobs via the gui if any databases have been moved.
Is there a way to automatically refresh the backup procs so that databases that have been removed are deleted from the backup proc, and when a database is added to a server this is by default added to the backup list.
If not is there a way to access/manipulate the list of databases that are selected to be backed up.
Apologies if there is a really obvious answer to this!
Many thanks
Paul
Is there a way to automatically refresh the backup procs so that databases that have been removed are deleted from the backup proc, and when a database is added to a server this is by default added to the backup list.
If not is there a way to access/manipulate the list of databases that are selected to be backed up.
Apologies if there is a really obvious answer to this!
Many thanks
Paul
Comments
To back up all databases:
To back up selected databases:
To back up all databases except those named:
You might need to modify the T-SQL command manually for the SQL Server Agent backup job to get the results you want.
SQL Backup Consultant Developer
Associate, Yohz Software
Beyond compression - SQL Backup goodies under the hood, updated for version 8
I've no problem with modifying the T-SQL command within the SQL Server Agent backup job. Cheers for the syntax.
So that I can automate the modification of the T-SQL command do you happen to know if it is possible to access the list of databases that sqlbackup is set to backup?
SQL Backup Consultant Developer
Associate, Yohz Software
Beyond compression - SQL Backup goodies under the hood, updated for version 8