Scheduled event cleanup by script
For automatic and efficient cleanup of the EVENT table, four SQL scripts are available in the \tools directory of your SafeGuard Enterprise software delivery:
-
spShrinkEventTable_install.sql
-
ScheduledShrinkEventTable_install.sql
-
spShrinkEventTable_uninstall.sql
-
ScheduledShrinkEventTable_uninstall.sql
The two scripts spShrinkEventTable_install.sql and ScheduledShrinkEventTable_install.sql install a stored procedure and a scheduled job at the database server. The scheduled job runs the stored procedure at defined regular intervals. The stored procedure moves events from the EVENT table to the backup log table EVENT_BACKUP leaving a defined number of latest events in the EVENT table.
The two scripts spShrinkEventTable_uninstall.sql and ScheduledShrinkEventTable_uninstall.sql uninstall the stored procedure and the scheduled job. These two scripts also delete the EVENT_BACKUP table.