1

I'm using SQL Server 2008. now I want to create a trigger for capturing Database Backup. I watched to DDL triggers. but did not find anything about backup.

EDIT : Really what i need to do. if someone will backup database i want to drop database. maybe it is not good to do it with trigger or event notification. if so then advise alternative way please

Simply, how drop database when someone will backup database

4

2 回答 2

1

您可以对事件使用事件通知AUDIT_BACKUP_RESTORE_EVENT

每当发出备份或恢复命令时,就会发生审核备份/恢复事件类。

于 2012-09-15T11:19:14.913 回答
0

You can find the backup history of all databases in the msdb database available for querying. I'm not aware of any push notification system for backups but you can do polling and query over historical data.

于 2012-09-15T10:47:01.167 回答